diff --git a/plugins-dev/remote-actions-extra/src/java/pt/lsts/neptus/plugins/remoteactionsextra/RemoteActionsExtra.java b/plugins-dev/remote-actions-extra/src/java/pt/lsts/neptus/plugins/remoteactionsextra/RemoteActionsExtra.java index 95c66b7a10..93b1c0572b 100644 --- a/plugins-dev/remote-actions-extra/src/java/pt/lsts/neptus/plugins/remoteactionsextra/RemoteActionsExtra.java +++ b/plugins-dev/remote-actions-extra/src/java/pt/lsts/neptus/plugins/remoteactionsextra/RemoteActionsExtra.java @@ -123,7 +123,6 @@ enum ActionTypeEnum { private String lastCmdBuilt = ""; private TakeControlMonitor takeControlMonitor; - private TakeControlMonitor takeControlMonitor2; @NeptusProperty(name = "OBS Entity Name", userLevel = NeptusProperty.LEVEL.ADVANCED, description = "Used to check the state of the OBS take control status.") @@ -137,8 +136,6 @@ public RemoteActionsExtra(ConsoleLayout console, boolean usedInsideAnotherConsol super(console, usedInsideAnotherConsolePanel); takeControlMonitor = new TakeControlMonitor(this); takeControlMonitor.setEntityName(obsEntityName); - takeControlMonitor2 = new TakeControlMonitor(this); - takeControlMonitor2.setEntityName(obsEntityName); } @Override @@ -149,18 +146,15 @@ public void initSubPanel() { @Override public void cleanSubPanel() { takeControlMonitor.setButton(null); - takeControlMonitor2.setButton(null); } @Override public void propertiesChanged() { takeControlMonitor.setEntityName(obsEntityName); - takeControlMonitor2.setEntityName(obsEntityName); } private synchronized void resetUIWithActions() { takeControlMonitor.setButton(null); - takeControlMonitor2.setButton(null); removeAll(); setLayout(new MigLayout("insets 10px")); @@ -198,11 +192,7 @@ private synchronized void resetUIWithActions() { if ("Take Control".equalsIgnoreCase(action)) { takeControlMonitor.setButton(button); takeControlMonitor.askedControl(); - } else if ("Relinquish Control".equalsIgnoreCase(action)) { - takeControlMonitor2.setButton(button); - takeControlMonitor2.askedControl(); } - break; case AXIS: case SLIDER: @@ -221,7 +211,6 @@ private synchronized void resetUIWithActions() { public void on(ConsoleEventMainSystemChange evt) { configureActions("", defaultAxisDecimalVal, false); takeControlMonitor.on(evt); - takeControlMonitor2.on(evt); } @Subscribe @@ -238,13 +227,11 @@ public void on(RemoteActionsRequest msg) { @Subscribe public void on(EntityState msg) { takeControlMonitor.on(msg); - takeControlMonitor2.on(msg); } @Subscribe public void on(VehicleState msg) { takeControlMonitor.on(msg); - takeControlMonitor2.on(msg); } @Periodic(millisBetweenUpdates = 1_000)