mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2026-08-15 18:43:59 +00:00
ControlCenter: add colorize distro toggle
This commit is contained in:
@@ -17,12 +17,14 @@ ColumnLayout {
|
||||
property string valueIcon: widgetData.icon !== undefined ? widgetData.icon : widgetMetadata.icon
|
||||
property bool valueUseDistroLogo: widgetData.useDistroLogo !== undefined ? widgetData.useDistroLogo : widgetMetadata.useDistroLogo
|
||||
property string valueCustomIconPath: widgetData.customIconPath !== undefined ? widgetData.customIconPath : ""
|
||||
property bool valueColorizeDistroLogo: widgetData.colorizeDistroLogo !== undefined ? widgetData.colorizeDistroLogo : (widgetMetadata.colorizeDistroLogo !== undefined ? widgetMetadata.colorizeDistroLogo : false)
|
||||
|
||||
function saveSettings() {
|
||||
var settings = Object.assign({}, widgetData || {})
|
||||
settings.icon = valueIcon
|
||||
settings.useDistroLogo = valueUseDistroLogo
|
||||
settings.customIconPath = valueCustomIconPath
|
||||
settings.colorizeDistroLogo = valueColorizeDistroLogo
|
||||
return settings
|
||||
}
|
||||
|
||||
@@ -39,6 +41,16 @@ ColumnLayout {
|
||||
}
|
||||
}
|
||||
|
||||
NToggle {
|
||||
visible: valueUseDistroLogo
|
||||
label: I18n.tr("bar.widget-settings.control-center.colorize-distro-logo.label")
|
||||
description: I18n.tr("bar.widget-settings.control-center.colorize-distro-logo.description")
|
||||
checked: valueColorizeDistroLogo
|
||||
onToggled: function (checked) {
|
||||
valueColorizeDistroLogo = checked
|
||||
}
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
spacing: Style.marginM
|
||||
|
||||
|
||||
@@ -761,10 +761,10 @@ ColumnLayout {
|
||||
NCheckbox {
|
||||
label: "Spicetify"
|
||||
description: ProgramCheckerService.spicetifyAvailable ? I18n.tr("settings.color-scheme.templates.programs.spicetify.description", {
|
||||
"filepath": "~/.config/spicetify/Themes/Comfy/color.ini"
|
||||
}) : I18n.tr("settings.color-scheme.templates.programs.spicetify.description-missing", {
|
||||
"app": "spicetify"
|
||||
})
|
||||
"filepath": "~/.config/spicetify/Themes/Comfy/color.ini"
|
||||
}) : I18n.tr("settings.color-scheme.templates.programs.spicetify.description-missing", {
|
||||
"app": "spicetify"
|
||||
})
|
||||
checked: Settings.data.templates.spicetify
|
||||
enabled: ProgramCheckerService.spicetifyAvailable
|
||||
opacity: ProgramCheckerService.spicetifyAvailable ? 1.0 : 0.6
|
||||
|
||||
Reference in New Issue
Block a user