summaryrefslogtreecommitdiffstats
path: root/src/extension/timer.cpp
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2007-09-01 04:36:03 +0000
committergouldtj <gouldtj@users.sourceforge.net>2007-09-01 04:36:03 +0000
commit776410582f483ba74ce1068ff0dc0e9f068fb5d7 (patch)
treed71a68250393725e3b54c691fe5939fddd625de3 /src/extension/timer.cpp
parentr16441@tres: ted | 2007-08-30 20:44:39 -0700 (diff)
downloadinkscape-776410582f483ba74ce1068ff0dc0e9f068fb5d7.tar.gz
inkscape-776410582f483ba74ce1068ff0dc0e9f068fb5d7.zip
r16442@tres: ted | 2007-08-30 21:51:42 -0700
One preference dialog per effect. Nothing crazy here. Also setting the timer to be ref counted in lock/unlock mode. This way the whole thing stays locked while the dialog is shown. (bzr r3653)
Diffstat (limited to 'src/extension/timer.cpp')
-rw-r--r--src/extension/timer.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/extension/timer.cpp b/src/extension/timer.cpp
index 0e7a6ad11..c7a9331a0 100644
--- a/src/extension/timer.cpp
+++ b/src/extension/timer.cpp
@@ -33,11 +33,10 @@ bool ExpirationTimer::timer_started = false;
the first timer extension, the timer is kicked off. This function
also sets up teh circularly linked list of all the timers.
*/
-ExpirationTimer::ExpirationTimer (Extension * in_extension)
+ExpirationTimer::ExpirationTimer (Extension * in_extension):
+ locked(0),
+ extension(in_extension)
{
- locked = false;
- extension = in_extension;
-
/* Fix Me! */
if (timer_list == NULL) {
next = this;
@@ -124,7 +123,7 @@ ExpirationTimer::touch (void)
bool
ExpirationTimer::expired (void) const
{
- if (locked) return false;
+ if (locked > 0) return false;
Glib::TimeVal current;
current.assign_current_time();