mirror of
https://github.com/zoriya/noctalia-shell.git
synced 2026-08-15 18:43:59 +00:00
NCircleStat + KeyboardLayout: converted to Layout
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import QtQuick
|
||||
import QtQuick.Layouts
|
||||
import Quickshell
|
||||
import Quickshell.Wayland
|
||||
import Quickshell.Io
|
||||
@@ -6,7 +7,7 @@ import qs.Commons
|
||||
import qs.Services
|
||||
import qs.Widgets
|
||||
|
||||
Row {
|
||||
RowLayout {
|
||||
id: root
|
||||
|
||||
property ShellScreen screen
|
||||
@@ -18,12 +19,17 @@ Row {
|
||||
// Use the shared service for keyboard layout
|
||||
property string currentLayout: KeyboardLayoutService.currentLayout
|
||||
|
||||
width: pill.width
|
||||
height: pill.height
|
||||
Layout.preferredWidth: pill.implicitWidth
|
||||
Layout.preferredHeight: pill.implicitHeight
|
||||
spacing: 0
|
||||
|
||||
NPill {
|
||||
id: pill
|
||||
|
||||
Layout.alignment: Qt.AlignCenter
|
||||
Layout.fillWidth: false
|
||||
Layout.fillHeight: false
|
||||
|
||||
rightOpen: BarWidgetRegistry.getNPillDirection(root)
|
||||
icon: "keyboard_alt"
|
||||
iconCircleColor: Color.mPrimary
|
||||
@@ -33,9 +39,8 @@ Row {
|
||||
tooltipText: "Keyboard layout: " + currentLayout
|
||||
|
||||
onClicked: {
|
||||
|
||||
// You could open keyboard settings here if needed
|
||||
// For now, just show the current layout
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user