mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-01-24 13:32:50 -05:00
fix gui
This commit is contained in:
@@ -241,7 +241,7 @@ Item {
|
||||
configFile: configDir + "/hypr/hyprland.conf",
|
||||
outputsFile: configDir + "/hypr/dms/outputs.conf",
|
||||
grepPattern: 'source.*dms/outputs.conf',
|
||||
includeLine: "source = ~/.config/hypr/dms/outputs.conf"
|
||||
includeLine: "source = ./dms/outputs.conf"
|
||||
}
|
||||
case "dwl":
|
||||
return {
|
||||
@@ -297,8 +297,10 @@ Item {
|
||||
`echo '${paths.includeLine}' >> "${paths.configFile}"; fi`
|
||||
], (output, exitCode) => {
|
||||
fixingInclude = false
|
||||
if (exitCode === 0)
|
||||
if (exitCode !== 0)
|
||||
return
|
||||
checkIncludeStatus()
|
||||
WlrOutputService.requestState()
|
||||
})
|
||||
}
|
||||
|
||||
@@ -974,17 +976,9 @@ Item {
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
DankButton {
|
||||
id: includeFixButton
|
||||
width: includeFixButtonText.implicitWidth + Theme.spacingL * 2
|
||||
height: Math.round(Theme.fontSizeMedium * 2.5)
|
||||
radius: Theme.cornerRadius
|
||||
visible: includeWarningBox.showError || includeWarningBox.showSetup
|
||||
color: root.fixingInclude ? Theme.withAlpha(Theme.error, 0.6) : Theme.error
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
|
||||
StyledText {
|
||||
id: includeFixButtonText
|
||||
text: {
|
||||
if (root.fixingInclude)
|
||||
return I18n.tr("Fixing...")
|
||||
@@ -992,22 +986,15 @@ Item {
|
||||
return I18n.tr("Setup")
|
||||
return I18n.tr("Fix Now")
|
||||
}
|
||||
font.pixelSize: Theme.fontSizeSmall
|
||||
font.weight: Font.Medium
|
||||
color: Theme.surface
|
||||
anchors.centerIn: parent
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
backgroundColor: Theme.primary
|
||||
textColor: Theme.primaryText
|
||||
enabled: !root.fixingInclude
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
onClicked: root.fixOutputsInclude()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
StyledRect {
|
||||
width: parent.width
|
||||
|
||||
@@ -328,40 +328,25 @@ Item {
|
||||
}
|
||||
}
|
||||
|
||||
Rectangle {
|
||||
DankButton {
|
||||
id: fixButton
|
||||
width: fixButtonText.implicitWidth + Theme.spacingL * 2
|
||||
height: Math.round(Theme.fontSizeMedium * 2.5)
|
||||
radius: Theme.cornerRadius
|
||||
visible: warningBox.showError || warningBox.showSetup
|
||||
color: KeybindsService.fixing ? Theme.withAlpha(Theme.error, 0.6) : Theme.error
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
|
||||
StyledText {
|
||||
id: fixButtonText
|
||||
text: {
|
||||
if (KeybindsService.fixing)
|
||||
return I18n.tr("Fixing...");
|
||||
return I18n.tr("Fixing...")
|
||||
if (warningBox.showSetup)
|
||||
return I18n.tr("Setup");
|
||||
return I18n.tr("Fix Now");
|
||||
return I18n.tr("Setup")
|
||||
return I18n.tr("Fix Now")
|
||||
}
|
||||
font.pixelSize: Theme.fontSizeSmall
|
||||
font.weight: Font.Medium
|
||||
color: Theme.surface
|
||||
anchors.centerIn: parent
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
cursorShape: Qt.PointingHandCursor
|
||||
backgroundColor: Theme.primary
|
||||
textColor: Theme.primaryText
|
||||
enabled: !KeybindsService.fixing
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
onClicked: KeybindsService.fixDmsBindsInclude()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
StyledRect {
|
||||
width: Math.min(650, parent.width - Theme.spacingL * 2)
|
||||
|
||||
Reference in New Issue
Block a user