@Override public void valueChange(ValueChangeEvent evt) { IValueConnector connector = (IValueConnector) evt.getSource(); if (!isRecycling(connector)) { RemoteFormattedValueState state = (RemoteFormattedValueState) ((IRemoteStateOwner) connector).getState(); RemoteValueCommand command = new RemoteValueCommand(); command.setTargetPeerGuid(state.getGuid()); command.setValue(state.getValue()); command.setValueAsObject(state.getValueAsObject()); remoteCommandHandler.registerCommand(command); } } };
/** * {@inheritDoc} */ @Override protected void showCardInPanel(RComponent cardsPeer, String cardName) { RemoteValueState cardState = cardsPeer.getState(); cardState.setValue(cardName); RemoteValueCommand command = new RemoteValueCommand(); command.setTargetPeerGuid(cardState.getGuid()); command.setValue(cardState.getValue()); getRemoteCommandHandler().registerCommand(command); }
@Override public void valueChange(ValueChangeEvent evt) { IValueConnector connector = (IValueConnector) evt.getSource(); // if (connector.getParentConnector() instanceof IRenderableCompositeValueConnector // && ((IRenderableCompositeValueConnector) connector // .getParentConnector()).getRenderingConnector() == connector) { // // don't listen to rendering connectors. // connector.removeValueChangeListener(this); // } else if (connector.getParentConnector() == null) { // // don't listen to root connectors. // connector.removeValueChangeListener(this); // } else { if (!isRecycling(connector)) { RemoteValueState state = ((IRemoteStateOwner) connector).getState(); RemoteValueCommand command = new RemoteValueCommand(); command.setTargetPeerGuid(state.getGuid()); command.setValue(state.getValue()); remoteCommandHandler.registerCommand(command); } // } } };
@Override public void valueChange(ValueChangeEvent evt) { IRenderableCompositeValueConnector connector = (IRenderableCompositeValueConnector) ((IValueConnector) evt .getSource()).getParentConnector(); if (!isRecycling(connector)) { RemoteCompositeValueState state = (RemoteCompositeValueState) ((IRemoteStateOwner) connector).getState(); RemoteValueCommand command = new RemoteValueCommand(); command.setTargetPeerGuid(state.getGuid()); command.setValue(state.getValue()); command.setDescription(state.getDescription()); command.setIconImageUrl(state.getIconImageUrl()); remoteCommandHandler.registerCommand(command); } } };