else if (e.getSource().equals(societyComponent)) { boolean wasModified = isModified(); if (e.getWhatChanged() == SocietyBase.SOCIETY_SAVED) { societyModified = false; } else { societyModified = true; }  if (isModified() != wasModified) super.fireModification(); } else fireModification();
return; } if (e.getWhatChanged() == SocietyBase.SOCIETY_SAVED || e.getWhatChanged() == RecipeBase.RECIPE_SAVED) return;   fireModification();
  private void notifyExperimentListeners(ModificationEvent e) {    if (e.getWhatChanged() == EXPERIMENT_SAVED)      super.fireModification();    else if (e.getSource().equals(societyComponent)) {      boolean wasModified = isModified();      if (e.getWhatChanged() == SocietyBase.SOCIETY_SAVED) {        societyModified = false;      } else {        societyModified = true;      }      // notify listeners only if overall modification status changed      if (isModified() != wasModified)        super.fireModification();    } else      fireModification();  }