index 3c46cb11e1ef0a8cf8d9966db156f42cdc23a930..03e4796bd4526be23a3448d42f471d3dd8de3a88 100644 (file)
* Released under GNU GPL, read the file 'COPYING' for more information
*/
+#include <algorithm>
#include "composite-undo-stack-observer.h"
#include "xml/event.h"
this->_unlock();
}
+void
+CompositeUndoStackObserver::notifyClearUndoEvent()
+{
+ this->_lock();
+ for(UndoObserverRecordList::iterator i = this->_active.begin(); i != _active.end(); ++i) {
+ if (!i->to_remove) {
+ i->issueClearUndo();
+ }
+ }
+ this->_unlock();
+}
+
+void
+CompositeUndoStackObserver::notifyClearRedoEvent()
+{
+ this->_lock();
+ for(UndoObserverRecordList::iterator i = this->_active.begin(); i != _active.end(); ++i) {
+ if (!i->to_remove) {
+ i->issueClearRedo();
+ }
+ }
+ this->_unlock();
+}
+
bool
CompositeUndoStackObserver::_remove_one(UndoObserverRecordList& list, UndoStackObserver& o)
{