wallpaper cropper slider inset icon, fixed disabled splitbutton state
This commit is contained in:
@@ -77,9 +77,9 @@ CustomMouseArea {
|
||||
anchors.leftMargin: -Appearance.padding.normal
|
||||
anchors.margins: -Appearance.padding.small
|
||||
anchors.rightMargin: -Appearance.padding.normal
|
||||
disabled: {
|
||||
enabled: {
|
||||
const now = new Date();
|
||||
return root.currMonth === now.getMonth() && root.currYear === now.getFullYear();
|
||||
return root.currMonth !== now.getMonth() || root.currYear !== now.getFullYear();
|
||||
}
|
||||
radius: Appearance.rounding.full
|
||||
|
||||
|
||||
@@ -296,7 +296,7 @@ Item {
|
||||
id: controlState
|
||||
|
||||
color: control.canUse ? DynamicColors.palette[`m3on${control.set_color}`] : DynamicColors.palette[`m3on${control.set_color}Container`]
|
||||
disabled: !control.canUse
|
||||
enabled: control.canUse
|
||||
|
||||
onClicked: {
|
||||
control.onClicked();
|
||||
|
||||
@@ -72,7 +72,7 @@ CustomRect {
|
||||
|
||||
CustomSplitButton {
|
||||
active: menuItems.find(m => root.props.recordingMode === m.icon + m.text) ?? menuItems[0]
|
||||
disabled: Recorder.running
|
||||
enabled: !Recorder.running
|
||||
|
||||
menuItems: [
|
||||
MenuItem {
|
||||
|
||||
@@ -243,7 +243,7 @@ SettingsPage {
|
||||
// id: timeInput
|
||||
//
|
||||
// readonly property bool highlighted: SettingsHighlight.highlightedSetting === name
|
||||
// property string name
|
||||
// property string name: "Schedule dark mode"
|
||||
// property var object
|
||||
// property list<string> settings
|
||||
// property bool shouldBeActive: true
|
||||
@@ -371,7 +371,20 @@ SettingsPage {
|
||||
// CustomRect {
|
||||
// Layout.preferredHeight: 72
|
||||
// Layout.preferredWidth: 96
|
||||
// color: startHourField.focus ? DynamicColors.palette.m3primaryContainer : DynamicColors.palette.m3surfaceContainer
|
||||
// color: startHourField.focus ? DynamicColors.palette.m3primaryContainer : DynamicColors.palette.m3surfaceContainerHighest
|
||||
// radius: Appearance.rounding.small
|
||||
//
|
||||
// CustomRect {
|
||||
// anchors.fill: parent
|
||||
// border.color: startHourField.focus ? DynamicColors.palette.m3onPrimaryContainer : DynamicColors.palette.m3surfaceContainerHighest
|
||||
// border.width: startHourField.focus ? 2 : 0
|
||||
// radius: parent.radius - border.width
|
||||
//
|
||||
// Behavior on border.width {
|
||||
// Anim {
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// CustomTextField {
|
||||
// id: startHourField
|
||||
@@ -384,9 +397,13 @@ SettingsPage {
|
||||
// return timeValue % 60;
|
||||
// }
|
||||
//
|
||||
// anchors.fill: parent
|
||||
// anchors.centerIn: parent
|
||||
// font.family: "Roboto"
|
||||
// font.pixelSize: 57
|
||||
// font.letterSpacing: -0.25
|
||||
// font.pixelSize: 50
|
||||
// font.weight: 400
|
||||
// implicitHeight: contentHeight
|
||||
// implicitWidth: parent.width
|
||||
// text: convertHour(Config.general.color.scheduleDarkStart)
|
||||
// }
|
||||
// }
|
||||
|
||||
@@ -70,7 +70,7 @@ CustomClippingRect {
|
||||
|
||||
StateLayer {
|
||||
color: DynamicColors.palette.m3onPrimary
|
||||
disabled: Updates.updating
|
||||
enabled: !Updates.updating
|
||||
|
||||
onClicked: Updates.performSystemUpdate()
|
||||
}
|
||||
|
||||
@@ -131,19 +131,17 @@ Item {
|
||||
anchors.left: parent.left
|
||||
anchors.right: parent.right
|
||||
implicitHeight: 30
|
||||
spacing: Appearance.spacing.large
|
||||
|
||||
CustomText {
|
||||
text: qsTr("Crop scale")
|
||||
}
|
||||
|
||||
CustomSlider {
|
||||
id: zoomSlider
|
||||
|
||||
Layout.fillWidth: true
|
||||
Layout.leftMargin: Appearance.padding.normal
|
||||
Layout.preferredHeight: Appearance.padding.larger * 3
|
||||
Layout.rightMargin: Appearance.padding.normal
|
||||
from: 1.0
|
||||
implicitHeight: Appearance.padding.larger * 3
|
||||
insetIcon: "crop"
|
||||
to: 5.0
|
||||
value: cropRectLoader.item ? cropRectLoader.item.zoom : 1.0
|
||||
|
||||
|
||||
@@ -103,7 +103,7 @@ StackView {
|
||||
implicitHeight: 30
|
||||
|
||||
StateLayer {
|
||||
disabled: !item.modelData.enabled
|
||||
enabled: item.modelData.enabled
|
||||
radius: item.radius
|
||||
|
||||
onClicked: {
|
||||
|
||||
Reference in New Issue
Block a user