Пример #1
0
 /**
  * Save the current station model
  *
  * @param fireChangeEvent Do we also fire the change event
  */
 private void doSave(boolean fireChangeEvent) {
   StationModel sm = getStationModel();
   smm.addUsers(sm);
   if (fireChangeEvent) {
     //            sm.firePropertyChangeEvent();
   }
   setHaveChanged(false);
 }
Пример #2
0
 /** Save the current station model under a new name */
 private void doSaveAs() {
   StationModel nl = getStationModel();
   String newName = smm.doSaveAs(nl, this);
   if (newName == null) {
     return;
   }
   nl = new StationModel(newName, new ArrayList(nl.getList()));
   setStationModel(nl, false);
   smm.addUsers(nl);
 }
Пример #3
0
 /** Create a new station model */
 protected void doNew() {
   if (!okToChange()) {
     return;
   }
   String newName = smm.doNew(this, "New", "model", "Provide a name for the model");
   if (newName == null) {
     return;
   }
   setStationModel(new StationModel(newName, new ArrayList()), true);
   smm.addUsers(getStationModel());
 }