Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7555 in orxonox.OLD for branches/qt_gui/src/lib/gui/gui.cc


Ignore:
Timestamp:
May 7, 2006, 2:25:16 PM (18 years ago)
Author:
bensch
Message:

orxonox/qt_gui: more elaborate Saveables

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/qt_gui/src/lib/gui/gui.cc

    r7548 r7555  
    4040  }
    4141
     42
     43  /**
     44   * @brief adds a SaveableGroup
     45   * @param saveableGroup the SaveableGroup to add to the SaveList.
     46   */
     47  void Gui::addSaveableGroup(SaveableGroup* saveableGroup)
     48  {
     49    if (std::find (this->groups.begin(), this->groups.end(), saveableGroup) == this->groups.end())
     50      this->groups.push_back(saveableGroup);
     51  }
     52
     53  /**
     54   * @brief removes a SaveableGroup
     55   * @param saveableGroup the SaveableGroup to remove from the SaveList.
     56   */
     57  void Gui::removeSaveableGroup(SaveableGroup* saveableGroup)
     58  {
     59    std::vector<SaveableGroup*>::iterator delElem = std::find (this->groups.begin(), this->groups.end(), saveableGroup);
     60    if (delElem != this->groups.end())
     61      this->groups.erase(delElem);
     62  }
     63
    4264  void Gui::quitEvent()
    4365  {
Note: See TracChangeset for help on using the changeset viewer.