/** * Defines the abstract method in <tt>AbstractPaneItem</tt>. * * <p>Applies the options currently set in this window, displaying an error message to the user if * a setting could not be applied. * * @throws IOException if the options could not be applied for some reason */ @Override public boolean applyOptions() throws IOException { if (!isDirty()) return false; StatusBarSettings.CONNECTION_QUALITY_DISPLAY_ENABLED.setValue(CHECK_BOX.isSelected()); GUIMediator.instance().getStatusLine().refresh(); return false; }
public boolean isDirty() { return StatusBarSettings.CONNECTION_QUALITY_DISPLAY_ENABLED.getValue() != CHECK_BOX.isSelected(); }
/** * Defines the abstract method in <tt>AbstractPaneItem</tt>. * * <p>Sets the options for the fields in this <tt>PaneItem</tt> when the window is shown. */ @Override public void initOptions() { CHECK_BOX.setSelected(StatusBarSettings.CONNECTION_QUALITY_DISPLAY_ENABLED.getValue()); }