🎉 FINALLY! Extra window in any wayland compositor
This required switching from a QML Window to a QQuickView in C++. I want to try to eventually subclass that in Rust, but for now it works. I'll have to still tinker with this to find out how to specifically set the screen in certain environments, but for now the user will need to move the window on their own.
This commit is contained in:
parent
bbc5bf3d7c
commit
b74e85bfe6
5 changed files with 98 additions and 42 deletions
|
@ -20,6 +20,7 @@ Kirigami.OverlaySheet {
|
|||
/* } */
|
||||
|
||||
Kirigami.FormLayout {
|
||||
implicitHeight: Kirigami.Units.gridUnit * 30
|
||||
Controls.ComboBox {
|
||||
id: screenSelectionField
|
||||
Kirigami.FormData.label: i18nc("@label:textbox", "Presentation Screen:")
|
||||
|
@ -27,6 +28,31 @@ Kirigami.OverlaySheet {
|
|||
textRole: "name"
|
||||
onActivated: {
|
||||
presentationScreen = screens[currentIndex];
|
||||
console.log(PresWindow.screen);
|
||||
PresWindow.screen = screens[currentIndex];
|
||||
console.log(PresWindow.screen);
|
||||
}
|
||||
|
||||
popup: Controls.Popup {
|
||||
y: screenSelectionField.height + 10
|
||||
z: 1000
|
||||
width: screenSelectionField.width
|
||||
implicitHeight: contentItem.implicitHeight
|
||||
padding: 1
|
||||
|
||||
contentItem: ListView {
|
||||
clip: true
|
||||
implicitHeight: contentHeight
|
||||
model: screenSelectionField.popup.visible ? screenSelectionField.delegateModel : null
|
||||
currentIndex: screenSelectionField.highlightedIndex
|
||||
|
||||
Controls.ScrollIndicator.vertical: Controls.ScrollIndicator { }
|
||||
}
|
||||
|
||||
background: Rectangle {
|
||||
border.color: Kirigami.Theme.hoverColor
|
||||
radius: 2
|
||||
}
|
||||
}
|
||||
}
|
||||
Controls.ToolButton {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue