private static void setConstraint(Node node, Object key, Object value) { if (value == null) { node.getProperties().remove(key); } else { node.getProperties().put(key, value); } if (node.getParent() != null) { node.getParent().requestLayout(); } }
/** * {@inheritDoc} */ @Override public void removePendingTask(final String taskKey) { this.pendingTasks.remove(taskKey); }
private void removeLocation(WorldMapView.Location location) { locationMap.remove(location); }
@Override public V remove(Object key) { return getDelegate().remove(key); }
properties.remove(key);
@Override public void onChanged(MapChangeListener.Change<? extends Object, ? extends Object> change) { if (change.getKey().equals("plusminusslidervalue")) { //$NON-NLS-1$ if (change.getValueAdded() != null) { Double valueAdded = (Double) change.getValueAdded(); value.set(valueAdded); change.getMap().remove("plusminusslidervalue"); //$NON-NLS-1$ } } }; });
/** * Removes all the decorations that have previously been set on the given node. * @param target The node from which all previously set decorations should be removed. */ public static final void removeAllDecorations(Node target) { List<Decoration> decorations = getDecorations(target, true); List<Decoration> removed = FXCollections.observableArrayList(decorations); target.getProperties().remove(DECORATIONS_PROPERTY_KEY); updateDecorationsOnNode(target, null, removed); }
private static void setConstraint(Node node, Object key, Object value) { if (value == null) { node.getProperties().remove(key); } else { node.getProperties().put(key, value); } if (node.getParent() != null) { node.getParent().requestLayout(); } }
/** * Remember a layout constraint * * @param node * the node * @param key * the constraint key * @param value * the value */ protected static void setConstraint(@NonNull Node node, @NonNull Object key, @Nullable Object value) { if (value == null) { node.getProperties().remove(key); } else { node.getProperties().put(key, value); } if (node.getParent() != null) { node.getParent().requestLayout(); } }
/** * Create the event handler to display the next person * @return mouse event handler */ private EventHandler<MouseEvent> createNextPersonHandler() { return mouseEvent -> { try { tavernState.talkingToProperty().get().remove(currentPerson.get()); List<ISideRoomPerson> persons = tavernState.presentPersonsInSideRoomBinding().get(); for (int i = 0; i < persons.size(); i++) { ISideRoomPerson person = persons.get(i); if (person.equals(currentPerson.get())) { if (i == persons.size() - 1) { currentPerson.set(persons.get(0)); } else { currentPerson.set(persons.get(i + 1)); } break; } } // end for tavernState.talkingToProperty().get().put(currentPerson.get(), city.getPlayer()); EDialogType nextPerson = map(currentPerson.get()); clientEventBus.post(new ViewChangeEvent(MainGameView.class, nextPerson)); } catch (RuntimeException e) { logger.error("Failed to switch to next person", e); } }; }
/** * Remember a layout constraint * * @param node * the node * @param key * the constraint key * @param value * the value */ protected static void setConstraint(@NonNull Node node, @NonNull Object key, @Nullable Object value) { if (value == null) { node.getProperties().remove(key); } else { node.getProperties().put(key, value); } if (node.getParent() != null) { node.getParent().requestLayout(); } }
CC cc = (CC) node.getProperties().remove(FXML_CC_KEY); FXComponentWrapper wrapper = new FXComponentWrapper(node);
box.selectionsProperty().remove(selection);