Changeset View
Changeset View
Standalone View
Standalone View
applets/keyboardindicator/contents/ui/main.qml
Show First 20 Lines • Show All 87 Lines • ▼ Show 20 Line(s) | 84 | PlasmaExtras.Heading { | |||
---|---|---|---|---|---|
88 | text: root.Plasmoid.toolTipSubText | 88 | text: root.Plasmoid.toolTipSubText | ||
89 | } | 89 | } | ||
90 | Item { | 90 | Item { | ||
91 | Layout.fillHeight: true | 91 | Layout.fillHeight: true | ||
92 | width: 5 | 92 | width: 5 | ||
93 | } | 93 | } | ||
94 | } | 94 | } | ||
95 | 95 | | |||
96 | Plasmoid.status: lockedCount>0 ? PlasmaCore.Types.ActiveStatus : PlasmaCore.Types.PassiveStatus | 96 | Plasmoid.status: lockedCount>0 ? PlasmaCore.Types.ActiveStatus : PlasmaCore.Types.HiddenStatus | ||
97 | Plasmoid.toolTipSubText: { | 97 | Plasmoid.toolTipSubText: { | ||
98 | var ret = ""; | 98 | var ret = ""; | ||
99 | var found = false; | 99 | var found = false; | ||
100 | for (var v in keystateSource.connectedSources) { | 100 | for (var v in keystateSource.connectedSources) { | ||
101 | var source = keystateSource.connectedSources[v] | 101 | var source = keystateSource.connectedSources[v] | ||
102 | var data = keystateSource.data[source]; | 102 | var data = keystateSource.data[source]; | ||
103 | if (data && data.Locked) { | 103 | if (data && data.Locked) { | ||
104 | found = true | 104 | found = true | ||
105 | ret+=i18n("%1: Locked\n", translate(source)) | 105 | ret+=i18n("%1: Locked\n", translate(source)) | ||
106 | } | 106 | } | ||
107 | } | 107 | } | ||
108 | return found ? ret.trim() : i18n("Unlocked") | 108 | return found ? ret.trim() : i18n("Unlocked") | ||
109 | } | 109 | } | ||
110 | } | 110 | } |