mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2025-12-05 21:15:38 -05:00
suppress niri toast initially
- matugen will trigger it on startup if auto t heming is enabled
This commit is contained in:
@@ -28,6 +28,7 @@ Singleton {
|
||||
|
||||
property string configValidationOutput: ""
|
||||
property bool hasInitialConnection: false
|
||||
property bool suppressConfigToast: true
|
||||
|
||||
readonly property string socketPath: Quickshell.env("NIRI_SOCKET")
|
||||
|
||||
@@ -344,13 +345,14 @@ Singleton {
|
||||
if (ToastService.toastVisible && ToastService.currentLevel === ToastService.levelError) {
|
||||
ToastService.hideToast()
|
||||
}
|
||||
if (hasInitialConnection) {
|
||||
if (hasInitialConnection && !suppressConfigToast) {
|
||||
ToastService.showInfo("niri: config reloaded")
|
||||
}
|
||||
}
|
||||
|
||||
if (!hasInitialConnection) {
|
||||
hasInitialConnection = true
|
||||
suppressToastTimer.start()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -555,4 +557,10 @@ Singleton {
|
||||
return niriMatch && niriMatch.niriWindow.workspace_id === currentWorkspaceId
|
||||
})
|
||||
}
|
||||
|
||||
Timer {
|
||||
id: suppressToastTimer
|
||||
interval: 3000
|
||||
onTriggered: suppressConfigToast = false
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user