public void setProperty(Property prop) { if (prop == null) { throw new NullPointerException("Property cannot be null"); //NOI18N } if (prop != this.prop) { this.prop = prop; prefSize = null; if (isShowing()) { firePropertyChange("preferredSize", null, null); //NOI18N } repaint(); } }
public void setProperty(Property prop) { if (prop == null) { throw new NullPointerException("Property cannot be null"); //NOI18N } if (prop != this.prop) { this.prop = prop; prefSize = null; if (isShowing()) { firePropertyChange("preferredSize",null,null); //NOI18N } repaint(); } }
public void setProperty(Property prop) { if (prop == null) { throw new NullPointerException("Property cannot be null"); //NOI18N } if (prop != this.prop) { this.prop = prop; prefSize = null; if (isShowing()) { firePropertyChange("preferredSize",null,null); //NOI18N } repaint(); } }
public void setUseLabels(boolean useLabels) { if (useLabels != this.useLabels) { Dimension oldPreferredSize = null; if (isShowing()) { JComponent innermost = findInnermostRenderer(getRenderer(this)); if (innermost instanceof RadioInplaceEditor || innermost instanceof JCheckBox) { oldPreferredSize = getPreferredSize(); } } this.useLabels = useLabels; if (oldPreferredSize != null) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N } } }
public void setRadioButtonMax(int i) { if (i != radioButtonMax) { Dimension oldPreferredSize = null; if (isShowing()) { oldPreferredSize = getPreferredSize(); } int old = radioButtonMax; radioButtonMax = i; if (oldPreferredSize != null) { //see if the change will affect anything PropertyEditor ed = PropUtils.getPropertyEditor(prop); String[] tags = ed.getTags(); if (tags != null) { if ((tags.length >= i) != (tags.length >= old)) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N } } } } }
public void setUseLabels(boolean useLabels) { if (useLabels != this.useLabels) { Dimension oldPreferredSize=null; if (isShowing()) { JComponent innermost = findInnermostRenderer(getRenderer(this)); if (innermost instanceof RadioInplaceEditor || innermost instanceof JCheckBox) { oldPreferredSize = getPreferredSize(); } } this.useLabels = useLabels; if (oldPreferredSize != null) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N } } }
public void setUseLabels(boolean useLabels) { if (useLabels != this.useLabels) { Dimension oldPreferredSize=null; if (isShowing()) { JComponent innermost = findInnermostRenderer(getRenderer(this)); if (innermost instanceof RadioInplaceEditor || innermost instanceof JCheckBox) { oldPreferredSize = getPreferredSize(); } } this.useLabels = useLabels; if (oldPreferredSize != null) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N } } }
public void setShowCustomEditorButton(boolean val) { //A property saying it doesn't want the custom editor button should //always override anything set on the property panel. if (getProperty() != null) { Boolean explicit = (Boolean) getProperty().getValue("suppressCustomEditor"); //NOI18N if (explicit != null) { val = explicit.booleanValue(); } } if (showCustomEditorButton != val) { prefSize = null; Dimension oldPreferredSize = null; if (isShowing()) { oldPreferredSize = getPreferredSize(); } showCustomEditorButton = val; if (oldPreferredSize != null) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N repaint(); } } }
public void setRadioButtonMax(int i) { if (i != radioButtonMax) { Dimension oldPreferredSize = null; if (isShowing()) { oldPreferredSize = getPreferredSize(); } int old = radioButtonMax; radioButtonMax = i; if (oldPreferredSize != null) { //see if the change will affect anything PropertyEditor ed = PropUtils.getPropertyEditor(prop); String[] tags = ed.getTags(); if (tags != null) { if (tags.length >= i != tags.length >= old) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N } } } } }
public void setShowCustomEditorButton(boolean val) { //A property saying it doesn't want the custom editor button should //always override anything set on the property panel. if (getProperty() != null) { Boolean explicit = (Boolean) getProperty().getValue( "suppressCustomEditor"); //NOI18N if (explicit != null) { val = explicit.booleanValue(); } } if (showCustomEditorButton != val) { prefSize = null; Dimension oldPreferredSize=null; if (isShowing()) { oldPreferredSize = getPreferredSize(); } showCustomEditorButton = val; if (oldPreferredSize != null) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N repaint(); } } }
public void setRadioButtonMax(int i) { if (i != radioButtonMax) { Dimension oldPreferredSize = null; if (isShowing()) { oldPreferredSize = getPreferredSize(); } int old = radioButtonMax; radioButtonMax = i; if (oldPreferredSize != null) { //see if the change will affect anything PropertyEditor ed = PropUtils.getPropertyEditor(prop); String[] tags = ed.getTags(); if (tags != null) { if (tags.length >= i != tags.length >= old) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N } } } } }
public void setShowCustomEditorButton(boolean val) { //A property saying it doesn't want the custom editor button should //always override anything set on the property panel. if (getProperty() != null) { Boolean explicit = (Boolean) getProperty().getValue( "suppressCustomEditor"); //NOI18N if (explicit != null) { val = explicit.booleanValue(); } } if (showCustomEditorButton != val) { prefSize = null; Dimension oldPreferredSize=null; if (isShowing()) { oldPreferredSize = getPreferredSize(); } showCustomEditorButton = val; if (oldPreferredSize != null) { firePropertyChange("preferredSize", oldPreferredSize, getPreferredSize()); //NOI18N repaint(); } } }