/** * Maps {@code JSpinner.getUI()} through queue */ public SpinnerUI getUI() { return (runMapping(new MapAction<SpinnerUI>("getUI") { @Override public SpinnerUI map() { return ((JSpinner) getSource()).getUI(); } })); }
/** * Maps {@code JSpinner.setUI(SpinnerUI)} through queue */ public void setUI(final SpinnerUI spinnerUI) { runMapping(new MapVoidAction("setUI") { @Override public void map() { ((JSpinner) getSource()).setUI(spinnerUI); } }); }
public void testSetGetUpdateUI() { assertEquals(spinner.getUIClassID(), "SpinnerUI"); SpinnerUI defaultUI = spinner.getUI(); assertNotNull(defaultUI); SpinnerUI ui = new SpinnerUI() { }; spinner.setUI(ui); assertEquals(ui, spinner.getUI()); assertTrue(propertyChangeController.isChanged("UI")); propertyChangeController.reset(); spinner.updateUI(); assertNotSame(ui, spinner.getUI()); assertTrue(propertyChangeController.isChanged("UI")); }
/** * This method resets the spinner's UI delegate to the default UI for the * current look and feel. */ public void updateUI() { setUI((SpinnerUI) UIManager.getUI(this)); }
public SpinnerUI getUI() { return (SpinnerUI) ui; }
public void setUI(SpinnerUI ui) { super.setUI(ui); }
@Override public void updateUI() { setUI((SpinnerUI) UIManager.getUI(this)); }
/** * Returns the look and feel (L&F) object that renders this component. * * @return the <code>SpinnerUI</code> object that renders this component */ public SpinnerUI getUI() { return (SpinnerUI)ui; }
/** * Sets the look and feel (L&F) object that renders this component. * * @param ui the <code>SpinnerUI</code> L&F object * @see UIDefaults#getUI */ public void setUI(SpinnerUI ui) { super.setUI(ui); }
/** * Resets the UI property with the value from the current look and feel. * * @see UIManager#getUI */ public void updateUI() { setUI((SpinnerUI)UIManager.getUI(this)); invalidate(); }