Fix QuickSwitcher activation
By making sure the global menu bar is disabled when not needed. This should also help with memory usage. Fix #482
This commit is contained in:
@@ -11,6 +11,12 @@ import org.kde.neochat 1.0
|
||||
QQC2.Popup {
|
||||
id: _popup
|
||||
|
||||
Shortcut {
|
||||
sequence: "Ctrl+K"
|
||||
enabled: !Kirigami.Settings.hasPlatformMenuBar
|
||||
onActivated: _popup.open()
|
||||
}
|
||||
|
||||
onVisibleChanged: {
|
||||
if (!visible) {
|
||||
return
|
||||
|
||||
@@ -40,7 +40,7 @@ Kirigami.ApplicationWindow {
|
||||
}
|
||||
|
||||
Loader {
|
||||
active: !Kirigami.Settings.isMobile
|
||||
active: Kirigami.Settings.hasPlatformMenuBar && !Kirigami.Settings.isMobile
|
||||
source: Qt.resolvedUrl("qrc:/imports/NeoChat/Menu/GlobalMenu.qml")
|
||||
}
|
||||
|
||||
@@ -66,16 +66,9 @@ Kirigami.ApplicationWindow {
|
||||
function onYChanged() { saveWindowGeometryTimer.restart(); }
|
||||
}
|
||||
|
||||
Shortcut {
|
||||
sequence: "Ctrl+K"
|
||||
onActivated: {
|
||||
quickView.item.open()
|
||||
}
|
||||
}
|
||||
|
||||
Loader {
|
||||
id: quickView
|
||||
|
||||
active: !Kirigami.Settings.isMobile
|
||||
sourceComponent: QuickSwitcher { }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user