native: add color function

This commit is contained in:
Johannes Jöns 2024-07-09 18:04:57 +02:00
parent 937921eb0f
commit e777e948e2

View file

@ -7,11 +7,15 @@ Window {
SystemPalette { id: inactiveColors; colorGroup: SystemPalette.Inactive }
SystemPalette { id: disabledColors; colorGroup: SystemPalette.Disabled }
function getColors() {
return root.active ? activeColors : inactiveColors;
}
id: root
width: 640
height: 480
visible: true
color: active ? activeColors.window : inactiveColors.window
color: getColors().window
title: qsTr("Alisa - License Managment")
@ -20,11 +24,11 @@ Window {
anchors {
top: parent.top
left: parent.left
right: parent.rightali
right: parent.right
}
height: 50
border.width: 5
border.color: root.active ? activeColors.accent : inactiveColors.accent
color: root.active ? activeColors.midlight : inactiveColors.midlight
border.color: getColors().accent
color: getColors().midlight
}
}