Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/UIElements/TextWindow.cpp

    r0188ea rf6bbc6  
    3939#include "Actions/MethodAction.hpp"
    4040#include "Actions/ErrorAction.hpp"
     41#include "Actions/ActionRegistry.hpp"
    4142#include "Views/StreamStringView.hpp"
    4243#include "Views/MethodStringView.hpp"
     
    5657  moleculeView = new StreamStringView(boost::bind(&MoleculeListClass::Enumerate,molecules,_1));
    5758  new DisplayMenuItem(main_menu,moleculeView,"Molecule List");
     59
     60  new SeperatorItem(main_menu);
     61
     62  Action* undoAction = ActionRegistry::getInstance().getActionByName("Undo");
     63  new ActionMenuItem('u',"Undo last operation",main_menu,undoAction);
     64
     65  Action* redoAction = ActionRegistry::getInstance().getActionByName("Redo");
     66  new ActionMenuItem('r',"Redo last operation",main_menu,redoAction);
    5867
    5968  new SeperatorItem(main_menu);
     
    94103  populaters.MakeEditMoleculesMenu(editMoleculesMenu,molecules,configuration,periode);
    95104
    96   returnFromEditMoleculeAction = new MethodAction("returnAction",boost::bind(&TextMenu::doQuit,editMoleculesMenu),false);
     105  Action *returnFromEditMoleculeAction = new TextMenu::LeaveAction(editMoleculesMenu);
    97106  MenuItem *returnItem = new ActionMenuItem('q',"return to Main menu",editMoleculesMenu,returnFromEditMoleculeAction);
    98107
     
    108117  delete old_menu;
    109118  delete quitAction;
    110   delete returnFromEditMoleculeAction;
    111119  delete moleculeView;
    112120  delete statusIndicator;
Note: See TracChangeset for help on using the changeset viewer.