/** In the case that some client properties may have been set before a * PropertyRenderer was added, set up its values accordingly. */ private void updateDisplayerFromClientProps() { String[] props = new String[] {"flat", "radioButtonMax", "suppressCustomEditor", "useLabels"}; //NOI18N for (int i=0; i < props.length; i++) { Object o = getClientProperty(props[i]); if (o != null) { updateDisplayerFromClientProp(props[i], o); } } }
/** In the case that some client properties may have been set before a * PropertyRenderer was added, set up its values accordingly. */ private void updateDisplayerFromClientProps() { String[] props = new String[] { "flat", "radioButtonMax", "suppressCustomEditor", "useLabels" }; //NOI18N for (int i = 0; i < props.length; i++) { Object o = getClientProperty(props[i]); if (o != null) { updateDisplayerFromClientProp(props[i], o); } } }
public void actionPerformed(ActionEvent e) { if( inner == e.getSource() && "enterPressed".equals(e.getActionCommand()) ) { //NOI18N Object beanBridge = getClientProperty("beanBridgeIdentifier"); //NOI18N if( null != beanBridge && beanBridge instanceof CellEditor ) { ((CellEditor)beanBridge).stopCellEditing(); } } } }
/** In the case that some client properties may have been set before a * PropertyRenderer was added, set up its values accordingly. */ private void updateDisplayerFromClientProps() { String[] props = new String[] {"flat", "radioButtonMax", "suppressCustomEditor", "useLabels"}; //NOI18N for (int i=0; i < props.length; i++) { Object o = getClientProperty(props[i]); if (o != null) { updateDisplayerFromClientProp(props[i], o); } } }
/** Update the current property displayer based on previously set client * properties */ private void updateDisplayerFromClientProp(String nm, Object val) { PropertyDisplayer displayer = getPropertyDisplayer(); if (displayer instanceof PropertyDisplayer_Inline) { PropertyDisplayer_Inline inline = (PropertyDisplayer_Inline) displayer; if ("flat".equals(nm)) { //NOI18N inline.setTableUI(Boolean.TRUE.equals(val)); if (Boolean.TRUE.equals(val)) { inline.setUseLabels(false); } else if (Boolean.FALSE.equals(val) && (getClientProperty("useLabels") == null)) { //NOI18N inline.setUseLabels(true); } } else if ("radioButtonMax".equals(nm)) { //NOI18N int max = (val instanceof Integer) ? ((Integer) val).intValue() : 0; inline.setRadioButtonMax(max); } else if ("suppressCustomEditor".equals(nm)) { //NOI18N inline.setShowCustomEditorButton(!Boolean.TRUE.equals(val)); } else if ("useLabels".equals(nm)) { //NOI18N inline.setUseLabels(Boolean.TRUE.equals(val)); } } }
/** Update the current property displayer based on previously set client * properties */ private void updateDisplayerFromClientProp (String nm, Object val) { PropertyDisplayer displayer = getPropertyDisplayer(); if (displayer instanceof PropertyDisplayer_Inline) { PropertyDisplayer_Inline inline = (PropertyDisplayer_Inline) displayer; if ("flat".equals(nm)) { //NOI18N inline.setTableUI(Boolean.TRUE.equals(val)); if (Boolean.TRUE.equals(val)) { inline.setUseLabels(false); } else if (Boolean.FALSE.equals(val) && getClientProperty("useLabels") == null) { //NOI18N inline.setUseLabels(true); } } else if ("radioButtonMax".equals(nm)) { //NOI18N int max = val instanceof Integer ? ((Integer) val).intValue() : 0; inline.setRadioButtonMax(max); } else if ("suppressCustomEditor".equals(nm)) { //NOI18N inline.setShowCustomEditorButton(!Boolean.TRUE.equals(val)); } else if ("useLabels".equals(nm)) { //NOI18N inline.setUseLabels(Boolean.TRUE.equals(val)); } } }
/** Update the current property displayer based on previously set client * properties */ private void updateDisplayerFromClientProp (String nm, Object val) { PropertyDisplayer displayer = getPropertyDisplayer(); if (displayer instanceof PropertyDisplayer_Inline) { PropertyDisplayer_Inline inline = (PropertyDisplayer_Inline) displayer; if ("flat".equals(nm)) { //NOI18N inline.setTableUI(Boolean.TRUE.equals(val)); if (Boolean.TRUE.equals(val)) { inline.setUseLabels(false); } else if (Boolean.FALSE.equals(val) && getClientProperty("useLabels") == null) { //NOI18N inline.setUseLabels(true); } } else if ("radioButtonMax".equals(nm)) { //NOI18N int max = val instanceof Integer ? ((Integer) val).intValue() : 0; inline.setRadioButtonMax(max); } else if ("suppressCustomEditor".equals(nm)) { //NOI18N inline.setShowCustomEditorButton(!Boolean.TRUE.equals(val)); } else if ("useLabels".equals(nm)) { //NOI18N inline.setUseLabels(Boolean.TRUE.equals(val)); } } }
/** Set or change the property this PropertyPanel will display * @param p the Property */ public final void setProperty(Node.Property p) { Object bridgeID = getClientProperty("beanBridgeIdentifier"); if (bridgeID != null) { TTVEnvBridge bridge = TTVEnvBridge.findInstance(bridgeID); if (bridge != null) { beans = bridge.getCurrentBeans(); bridge.clear(); } } if (p != prop) { prop = p; if (!settingModel) { //model will be recreated dynamically model = null; } if (displayer != null) { if (displayer instanceof PropertyDisplayer_Mutable) { ((PropertyDisplayer_Mutable) displayer).setProperty(p); } else { hardReset(); } } } }
/** Set or change the property this PropertyPanel will display * @param p the Property */ public final void setProperty (Node.Property p) { Object bridgeID = getClientProperty("beanBridgeIdentifier"); if (bridgeID != null) { TTVEnvBridge bridge = TTVEnvBridge.findInstance(bridgeID); if (bridge != null) { beans = bridge.getCurrentBeans(); bridge.clear(); } } if (p != prop) { prop = p; if (!settingModel) { //model will be recreated dynamically model = null; } if (displayer != null) { if (displayer instanceof PropertyDisplayer_Mutable) { ((PropertyDisplayer_Mutable) displayer).setProperty(p); } else { hardReset(); } } } }
/** Set or change the property this PropertyPanel will display * @param p the Property */ public final void setProperty (Node.Property p) { Object bridgeID = getClientProperty("beanBridgeIdentifier"); if (bridgeID != null) { TTVEnvBridge bridge = TTVEnvBridge.findInstance(bridgeID); if (bridge != null) { beans = bridge.getCurrentBeans(); bridge.clear(); } } if (p != prop) { prop = p; if (!settingModel) { //model will be recreated dynamically model = null; } if (displayer != null) { if (displayer instanceof PropertyDisplayer_Mutable) { ((PropertyDisplayer_Mutable) displayer).setProperty(p); } else { hardReset(); } } } }
PropertyDisplayer_Inline inline = (PropertyDisplayer_Inline) result; boolean tableUI = (preferences & PREF_TABLEUI) != 0 || Boolean.TRUE.equals(getClientProperty("flat")); //NOI18N
boolean tableUI = ((preferences & PREF_TABLEUI) != 0) || Boolean.TRUE.equals(getClientProperty("flat")); //NOI18N
PropertyDisplayer_Inline inline = (PropertyDisplayer_Inline) result; boolean tableUI = (preferences & PREF_TABLEUI) != 0 || Boolean.TRUE.equals(getClientProperty("flat")); //NOI18N