diff --git a/src/backend/sgpemv2/history.hh b/src/backend/sgpemv2/history.hh index 100bd93..6148d17 100644 --- a/src/backend/sgpemv2/history.hh +++ b/src/backend/sgpemv2/history.hh @@ -146,6 +146,9 @@ namespace sgpem void notify_change(); + position _front; + + private: /** \brief Enable/disable notifications to registered observers * * This is quite useful to disable momentarily notification while you @@ -156,9 +159,6 @@ namespace sgpem */ bool set_notify_enabled(bool enabled = true); - position _front; - - private: bool _notify; }; //~ class History @@ -169,6 +169,8 @@ namespace sgpem * History that would reset it / notify its observers. For example, when loading * from a file. In this case, create an object of this type on the stack. * The destructor will take care of re-enabling notifications. + * + * Locks can be taken recursively without fear. */ class SG_DLLEXPORT History::LockNotify { diff --git a/src/backend/sgpemv2/simulation.hh b/src/backend/sgpemv2/simulation.hh index 69275b0..b895c2c 100644 --- a/src/backend/sgpemv2/simulation.hh +++ b/src/backend/sgpemv2/simulation.hh @@ -177,6 +177,11 @@ namespace sgpem typedef std::vector RegisteredObservers; RegisteredObservers _observers; + Simulation(); // Constructor + + void notify_change(); + + private: /** \brief Enable/disable notifications to registered observers * * This is quite useful to disable momentarily notification while you @@ -187,11 +192,6 @@ namespace sgpem */ bool set_notify_enabled(bool enabled = true); - Simulation(); // Constructor - - void notify_change(); - - private: bool _notify; }; //~ class Simulation @@ -201,6 +201,8 @@ namespace sgpem * Simulation that would reset it / notify its observers. For example, when loading * from a file. In this case, create an object of this type on the stack. * The destructor will take care of re-enabling notifications. + * + * Locks can be taken recursively without fear. */ class SG_DLLEXPORT Simulation::LockNotify {