@@ -48,6 +48,9 @@ QtObject {
4848 nextIndex = currentKeymapIndex + 1;
4949 }
5050 currentKeymapIndex = nextIndex;
51+ if (actionGroup.currentAction.valid) {
52+ actionGroup.currentAction.updateState(currentKeymapIndex);
53+ }
5154 }
5255
5356 function previousKeymap() {
@@ -57,6 +60,9 @@ QtObject {
5760 prevIndex = currentKeymapIndex - 1;
5861 }
5962 currentKeymapIndex = prevIndex;
63+ if (actionGroup.currentAction.valid) {
64+ actionGroup.currentAction.updateState(currentKeymapIndex);
65+ }
6066 }
6167
6268 property Binding surfaceKeymapBinding: Binding { // NB: needed mainly for xmir & libertine apps
@@ -77,18 +83,12 @@ QtObject {
7783 busName: "com.canonical.indicator.keyboard"
7884 objectPath: "/com/canonical/indicator/keyboard"
7985
80− property variant currentAction: action("current")
81− property variant activeAction: action("active")
86+ property variant currentAction: action("current") // the one that's checked by the indicator
87+ property variant activeAction: action("active") // the one that we clicked
8288
8389 Component.onCompleted: actionGroup.start();
8490 }
8591
86− onCurrentKeymapIndexChanged: {
87− if (actionGroup.currentAction.valid) {
88− actionGroup.currentAction.updateState(currentKeymapIndex);
89− }
90− }
91−
9292 readonly property int activeActionState: actionGroup.activeAction.valid ? actionGroup.activeAction.state : -1
9393
9494 onActiveActionStateChanged: {