mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2025-12-06 05:25:41 -05:00
modals: move HyprFocusGrab out of common Modal
This commit is contained in:
@@ -1,4 +1,6 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
import qs.Services
|
import qs.Services
|
||||||
@@ -9,6 +11,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:bluetooth-pairing"
|
layerNamespace: "dms:bluetooth-pairing"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [root]
|
||||||
|
active: CompositorService.isHyprland && root.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property string deviceName: ""
|
property string deviceName: ""
|
||||||
property string deviceAddress: ""
|
property string deviceAddress: ""
|
||||||
property string requestType: ""
|
property string requestType: ""
|
||||||
|
|||||||
@@ -3,6 +3,7 @@ pragma ComponentBehavior: Bound
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
import Quickshell
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import Quickshell.Io
|
import Quickshell.Io
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
@@ -14,6 +15,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:clipboard"
|
layerNamespace: "dms:clipboard"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [clipboardHistoryModal]
|
||||||
|
active: CompositorService.isHyprland && clipboardHistoryModal.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property int totalCount: 0
|
property int totalCount: 0
|
||||||
property var clipboardEntries: []
|
property var clipboardEntries: []
|
||||||
property string searchText: ""
|
property string searchText: ""
|
||||||
|
|||||||
@@ -95,11 +95,6 @@ PanelWindow {
|
|||||||
return WlrKeyboardFocus.Exclusive
|
return WlrKeyboardFocus.Exclusive
|
||||||
}
|
}
|
||||||
|
|
||||||
HyprlandFocusGrab {
|
|
||||||
windows: [root]
|
|
||||||
active: CompositorService.isHyprland && shouldHaveFocus
|
|
||||||
}
|
|
||||||
|
|
||||||
onVisibleChanged: {
|
onVisibleChanged: {
|
||||||
if (root.visible) {
|
if (root.visible) {
|
||||||
opened()
|
opened()
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
import Quickshell
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import Quickshell.Io
|
import Quickshell.Io
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
@@ -12,6 +13,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:color-picker"
|
layerNamespace: "dms:color-picker"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [root]
|
||||||
|
active: CompositorService.isHyprland && root.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property string pickerTitle: "Choose Color"
|
property string pickerTitle: "Choose Color"
|
||||||
property color selectedColor: SessionData.recentColors.length > 0 ? SessionData.recentColors[0] : Theme.primary
|
property color selectedColor: SessionData.recentColors.length > 0 ? SessionData.recentColors[0] : Theme.primary
|
||||||
property var onColorSelectedCallback: null
|
property var onColorSelectedCallback: null
|
||||||
|
|||||||
@@ -2,6 +2,8 @@ import Qt.labs.folderlistmodel
|
|||||||
import QtCore
|
import QtCore
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import Quickshell.Io
|
import Quickshell.Io
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
@@ -13,6 +15,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:file-browser"
|
layerNamespace: "dms:file-browser"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [fileBrowserModal]
|
||||||
|
active: CompositorService.isHyprland && fileBrowserModal.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
keepPopoutsOpen: true
|
keepPopoutsOpen: true
|
||||||
|
|
||||||
property string homeDir: StandardPaths.writableLocation(StandardPaths.HomeLocation)
|
property string homeDir: StandardPaths.writableLocation(StandardPaths.HomeLocation)
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import Quickshell.Io
|
import Quickshell.Io
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
@@ -11,6 +13,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:notification-center-modal"
|
layerNamespace: "dms:notification-center-modal"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [notificationModal]
|
||||||
|
active: CompositorService.isHyprland && notificationModal.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property bool notificationModalOpen: false
|
property bool notificationModalOpen: false
|
||||||
property var notificationListRef: null
|
property var notificationListRef: null
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
import qs.Services
|
import qs.Services
|
||||||
@@ -9,6 +11,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:polkit"
|
layerNamespace: "dms:polkit"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [root]
|
||||||
|
active: CompositorService.isHyprland && root.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property string passwordInput: ""
|
property string passwordInput: ""
|
||||||
property var currentFlow: PolkitService.agent?.flow
|
property var currentFlow: PolkitService.agent?.flow
|
||||||
property bool isLoading: false
|
property bool isLoading: false
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
import Quickshell
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
import qs.Services
|
import qs.Services
|
||||||
@@ -10,6 +11,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:power-menu"
|
layerNamespace: "dms:power-menu"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [root]
|
||||||
|
active: CompositorService.isHyprland && root.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property int selectedIndex: 0
|
property int selectedIndex: 0
|
||||||
property int selectedRow: 0
|
property int selectedRow: 0
|
||||||
property int selectedCol: 0
|
property int selectedCol: 0
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import Quickshell.Io
|
import Quickshell.Io
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
@@ -13,6 +15,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:settings"
|
layerNamespace: "dms:settings"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [settingsModal]
|
||||||
|
active: CompositorService.isHyprland && settingsModal.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property Component settingsContent
|
property Component settingsContent
|
||||||
property alias profileBrowser: profileBrowser
|
property alias profileBrowser: profileBrowser
|
||||||
property int currentTabIndex: 0
|
property int currentTabIndex: 0
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
import Quickshell
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import Quickshell.Io
|
import Quickshell.Io
|
||||||
import Quickshell.Widgets
|
import Quickshell.Widgets
|
||||||
import qs.Common
|
import qs.Common
|
||||||
@@ -14,6 +15,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:spotlight"
|
layerNamespace: "dms:spotlight"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [spotlightModal]
|
||||||
|
active: CompositorService.isHyprland && spotlightModal.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property bool spotlightOpen: false
|
property bool spotlightOpen: false
|
||||||
property alias spotlightContent: spotlightContentInstance
|
property alias spotlightContent: spotlightContentInstance
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
import QtQuick
|
import QtQuick
|
||||||
|
import Quickshell
|
||||||
|
import Quickshell.Hyprland
|
||||||
import qs.Common
|
import qs.Common
|
||||||
import qs.Modals.Common
|
import qs.Modals.Common
|
||||||
import qs.Services
|
import qs.Services
|
||||||
@@ -9,6 +11,11 @@ DankModal {
|
|||||||
|
|
||||||
layerNamespace: "dms:wifi-password"
|
layerNamespace: "dms:wifi-password"
|
||||||
|
|
||||||
|
HyprlandFocusGrab {
|
||||||
|
windows: [root]
|
||||||
|
active: CompositorService.isHyprland && root.shouldHaveFocus
|
||||||
|
}
|
||||||
|
|
||||||
property string wifiPasswordSSID: ""
|
property string wifiPasswordSSID: ""
|
||||||
property string wifiPasswordInput: ""
|
property string wifiPasswordInput: ""
|
||||||
property string wifiUsernameInput: ""
|
property string wifiUsernameInput: ""
|
||||||
|
|||||||
@@ -375,11 +375,6 @@ Item {
|
|||||||
WlrLayershell.namespace: "dms:tray-overflow-menu"
|
WlrLayershell.namespace: "dms:tray-overflow-menu"
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
|
|
||||||
HyprlandFocusGrab {
|
|
||||||
windows: [overflowMenu]
|
|
||||||
active: CompositorService.isHyprland && root.menuOpen
|
|
||||||
}
|
|
||||||
|
|
||||||
anchors {
|
anchors {
|
||||||
top: true
|
top: true
|
||||||
left: true
|
left: true
|
||||||
@@ -821,11 +816,6 @@ Item {
|
|||||||
}
|
}
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
|
|
||||||
HyprlandFocusGrab {
|
|
||||||
windows: [menuWindow]
|
|
||||||
active: CompositorService.isHyprland && menuRoot.showMenu
|
|
||||||
}
|
|
||||||
|
|
||||||
anchors {
|
anchors {
|
||||||
top: true
|
top: true
|
||||||
left: true
|
left: true
|
||||||
|
|||||||
Reference in New Issue
Block a user