Code

Add a warning to sp-object.h to not use some of the new methods
[inkscape.git] / src / composite-undo-stack-observer.cpp
index 85d7aed13242d58f4706c892a18c7ec6e1562aee..03e4796bd4526be23a3448d42f471d3dd8de3a88 100644 (file)
@@ -79,6 +79,30 @@ CompositeUndoStackObserver::notifyUndoCommitEvent(Event* log)
        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)
 {