]> git.lyx.org Git - lyx.git/blobdiff - sigc++/thread.h
Mostly fixed the 'empty paragraph deletion kills the cursor' problem; and initialise...
[lyx.git] / sigc++ / thread.h
index 188738c60d88303fb1998c5fd732e1c58bd47504..aa9aa380c2e69377244a70beb10e57846005949b 100644 (file)
@@ -121,7 +121,7 @@ struct Condition
 
      // unlocks a mutex while waiting on a condition, then reaquires lock
      // with a fixed maximum duration.
-     int wait(Mutex &m, struct timespec* spec);
+     int wait(Mutex &m,struct timespec* spec);
 
   };
 
@@ -191,13 +191,13 @@ class Private<int> : private Private_
         int& operator =(const int& t)
           {return (((int&)*this)=t);}
 
-         operator int& ();
-          //{
-          // int *value=(int*)get();
-          // if (!value)
-          //   set((void*)(value=new int(0)));  
-          // return *(value); 
-          //}
+        operator int& ()
+          {
+           int *value=(int*)get();
+           if (!value)
+             set((void*)(value=new int(0)));  
+           return *(value); 
+          }
 
         Private() { create(&dtor); }
         ~Private() { destroy(); }