Skip to content

Commit 2a58b8e

Browse files
authored
[freeboxos] Add missing thing actions for active player (openhab#17877)
Fix openhab#17874 Signed-off-by: Laurent Garnier <[email protected]>
1 parent 9b4ee48 commit 2a58b8e

File tree

1 file changed

+27
-0
lines changed
  • bundles/org.openhab.binding.freeboxos/src/main/java/org/openhab/binding/freeboxos/internal/action

1 file changed

+27
-0
lines changed

bundles/org.openhab.binding.freeboxos/src/main/java/org/openhab/binding/freeboxos/internal/action/ActivePlayerActions.java

+27
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
import org.eclipse.jdt.annotation.NonNullByDefault;
1616
import org.openhab.binding.freeboxos.internal.handler.ActivePlayerHandler;
1717
import org.openhab.binding.freeboxos.internal.handler.PlayerHandler;
18+
import org.openhab.core.automation.annotation.ActionInput;
1819
import org.openhab.core.automation.annotation.RuleAction;
1920
import org.openhab.core.thing.binding.ThingActions;
2021
import org.openhab.core.thing.binding.ThingActionsScope;
@@ -52,4 +53,30 @@ public static void rebootPlayer(ThingActions actions) {
5253
throw new IllegalArgumentException("actions parameter is not an ActivePlayerActions class.");
5354
}
5455
}
56+
57+
@Override
58+
@RuleAction(label = "@text/action.sendKey.label", description = "@text/action.sendKey.description")
59+
public void sendKey(@ActionInput(name = "key", label = "@text/action.input.key.label") String key) {
60+
super.sendKey(key);
61+
}
62+
63+
@Override
64+
@RuleAction(label = "@text/action.sendLongKey.label", description = "@text/action.sendLongKey.description")
65+
public void sendLongKey(@ActionInput(name = "key", label = "@text/action.input.key.label") String key) {
66+
super.sendLongKey(key);
67+
}
68+
69+
@Override
70+
@RuleAction(label = "@text/action.sendMultipleKeys.label", description = "@text/action.sendMultipleKeys.description")
71+
public void sendMultipleKeys(
72+
@ActionInput(name = "keys", label = "@text/action.sendMultipleKeys.input.keys.label", description = "@text/action.sendMultipleKeys.input.keys.description") String keys) {
73+
super.sendMultipleKeys(keys);
74+
}
75+
76+
@Override
77+
@RuleAction(label = "@text/action.sendKeyRepeat.label", description = "@text/action.sendKeyRepeat.description")
78+
public void sendKeyRepeat(@ActionInput(name = "key", label = "@text/action.input.key.label") String key,
79+
@ActionInput(name = "count", label = "@text/action.sendKeyRepeat.input.count.label", description = "@text/action.sendKeyRepeat.input.count.description") int count) {
80+
super.sendKeyRepeat(key, count);
81+
}
5582
}

0 commit comments

Comments
 (0)