add squeekboard toggle button
This commit is contained in:
@@ -59,6 +59,10 @@ PanelWindow {
|
||||
Layout.fillHeight: true
|
||||
}
|
||||
|
||||
OskMenu {
|
||||
Layout.fillHeight: true
|
||||
}
|
||||
|
||||
WifiMenu {
|
||||
bar: bar
|
||||
Layout.fillHeight: true
|
||||
|
||||
@@ -0,0 +1,32 @@
|
||||
import QtQuick
|
||||
import qs.config
|
||||
import qs.components
|
||||
import qs.services
|
||||
|
||||
// Right section: the on-screen keyboard button. No menu behind it — a click
|
||||
// shows squeekboard, another hides it.
|
||||
Item {
|
||||
id: root
|
||||
|
||||
// Machines with no squeekboard unit get no button at all.
|
||||
visible: Osk.available
|
||||
|
||||
implicitWidth: button.implicitWidth
|
||||
|
||||
PanelButton {
|
||||
id: button
|
||||
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
height: root.height - Theme.spacing
|
||||
minContentWidth: Theme.iconSize
|
||||
active: Osk.shown
|
||||
activeColor: Theme.accent
|
||||
|
||||
onClicked: Osk.toggle()
|
||||
|
||||
KeyboardGlyph {
|
||||
size: Theme.iconSize
|
||||
color: button.active ? Theme.background : Theme.text
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user