source: molecuilder/src/Actions/ActionSequence.hpp@ 770138

Last change on this file since 770138 was 521e29, checked in by Tillmann Crueger <crueger@…>, 15 years ago

Switched type of pointer used for ActionStates

  • Property mode set to 100644
File size: 653 bytes
Line 
1/*
2 * ActionSequenze.hpp
3 *
4 * Created on: Dec 17, 2009
5 * Author: crueger
6 */
7
8#ifndef ACTIONSEQUENZE_HPP_
9#define ACTIONSEQUENZE_HPP_
10
11#include "Actions/Action.hpp"
12
13#include <deque>
14
15/**
16 * Store Actions for later use.
17 */
18class ActionSequence
19{
20public:
21 typedef std::deque<Action*> actionSet;
22 typedef std::deque<Action::state_ptr> stateSet;
23
24 ActionSequence();
25 virtual ~ActionSequence();
26
27 void addAction(Action*);
28 Action* removeLastAction();
29
30 stateSet callAll();
31 stateSet undoAll(stateSet);
32 stateSet redoAll(stateSet);
33
34 bool canUndo();
35 bool shouldUndo();
36
37private:
38 actionSet actions;
39};
40
41#endif /* ACTIONSEQUENZE_HPP_ */
Note: See TracBrowser for help on using the repository browser.