Renamed all tabs qml, so its easier to distinguish them from services
This commit is contained in:
parent
eac335ab95
commit
39cc72f067
13 changed files with 80 additions and 22 deletions
|
|
@ -318,17 +318,17 @@ NLoader {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
currentIndex: currentTabIndex
|
currentIndex: currentTabIndex
|
||||||
|
|
||||||
Tabs.General {}
|
Tabs.GeneralTab {}
|
||||||
Tabs.Bar {}
|
Tabs.BarTab {}
|
||||||
Tabs.Audio {}
|
Tabs.AudioTab {}
|
||||||
Tabs.Display {}
|
Tabs.DisplayTab {}
|
||||||
Tabs.Network {}
|
Tabs.NetworkTab {}
|
||||||
Tabs.TimeWeather {}
|
Tabs.TimeWeatherTab {}
|
||||||
Tabs.ColorScheme {}
|
Tabs.ColorSchemeTab {}
|
||||||
Tabs.Wallpaper {}
|
Tabs.WallpaperTab {}
|
||||||
Tabs.WallpaperSelector {}
|
Tabs.WallpaperSelectorTab {}
|
||||||
Tabs.ScreenRecorder {}
|
Tabs.ScreenRecorderTab {}
|
||||||
Tabs.About {}
|
Tabs.AboutTab {}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,12 @@ ColumnLayout {
|
||||||
|
|
||||||
spacing: 0
|
spacing: 0
|
||||||
|
|
||||||
|
// Component.onCompleted: {
|
||||||
|
// console.log("[ColorSchemes] Service initialized")
|
||||||
|
// ColorScheme.loadColorSchemes()
|
||||||
|
// }
|
||||||
|
|
||||||
|
|
||||||
// property var colorSchemes: [{
|
// property var colorSchemes: [{
|
||||||
// "label": "Generated from Wallpaper (Matugen required)"
|
// "label": "Generated from Wallpaper (Matugen required)"
|
||||||
// }, {
|
// }, {
|
||||||
|
|
@ -24,7 +30,6 @@ ColumnLayout {
|
||||||
// "label": "Rosé Pine",
|
// "label": "Rosé Pine",
|
||||||
// "file": "rosepine.json"
|
// "file": "rosepine.json"
|
||||||
// }]
|
// }]
|
||||||
|
|
||||||
ScrollView {
|
ScrollView {
|
||||||
id: scrollView
|
id: scrollView
|
||||||
|
|
||||||
|
|
@ -56,18 +61,22 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
|
|
||||||
ButtonGroup {
|
ButtonGroup {
|
||||||
id: schemes
|
id: schemesGroup
|
||||||
}
|
}
|
||||||
|
|
||||||
// Repeater {
|
Repeater {
|
||||||
// model: root.colorSchemes
|
model: ColorSchemes.schemes
|
||||||
// ButtonGroup.group: schemes
|
delegate: NRadioButton {
|
||||||
// NRadioButton {
|
ButtonGroup.group: schemesGroup
|
||||||
// // checked: Audio.sink?.id === modelData.id
|
// checked: Audio.sink?.id === modelData.id
|
||||||
// //onClicked: Audio.setAudioSink(modelData)
|
//onClicked: Audio.setAudioSink(modelData)
|
||||||
// text: modelData.label
|
text: {
|
||||||
// }
|
console.log(modelData.fileName)
|
||||||
// }
|
return modelData.fileName
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
49
Services/ColorSchemes.qml
Normal file
49
Services/ColorSchemes.qml
Normal file
|
|
@ -0,0 +1,49 @@
|
||||||
|
pragma Singleton
|
||||||
|
|
||||||
|
import QtQuick
|
||||||
|
import Qt.labs.folderlistmodel
|
||||||
|
import Quickshell
|
||||||
|
import Quickshell.Io
|
||||||
|
|
||||||
|
Singleton {
|
||||||
|
id: root
|
||||||
|
|
||||||
|
// Component.onCompleted: {
|
||||||
|
// console.log("[ColorSchemes] Service initialized")
|
||||||
|
// loadColorSchemes()
|
||||||
|
// }
|
||||||
|
|
||||||
|
// property var schemes: []
|
||||||
|
// //property string currentScheme: Settings.data.wallpaper.current
|
||||||
|
// property bool scanning: false
|
||||||
|
|
||||||
|
// function loadColorSchemes() {
|
||||||
|
// scanning = true
|
||||||
|
// schemes = []
|
||||||
|
// // Unsetting, then setting the folder will re-trigger the parsing!
|
||||||
|
// folderModel.folder = ""
|
||||||
|
// folderModel.folder = "file://" + Quickshell.shellDir + "/Assets/Matugen/ColorSchemes"
|
||||||
|
// }
|
||||||
|
|
||||||
|
// FolderListModel {
|
||||||
|
// id: folderModel
|
||||||
|
// nameFilters: ["*.json"]
|
||||||
|
// showDirs: false
|
||||||
|
// sortField: FolderListModel.Name
|
||||||
|
// onStatusChanged: {
|
||||||
|
// console.log("sasfjsaflkhfkjhasf")
|
||||||
|
// if (status === FolderListModel.Ready) {
|
||||||
|
// var files = []
|
||||||
|
// for (var i = 0; i < count; i++) {
|
||||||
|
// console.log(get(i, "fileName"))
|
||||||
|
// // var filepath = (Settings.data.wallpaper.directory !== undefined ? Settings.data.wallpaper.directory : "") + "/" + get(
|
||||||
|
// // i, "fileName")
|
||||||
|
// // files.push(filepath)
|
||||||
|
// }
|
||||||
|
// schemes = files
|
||||||
|
// scanning = false
|
||||||
|
// console.log(schemes)
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
// }
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue