]> git.mxchange.org Git - simgear.git/blobdiff - simgear/structure/event_mgr.hxx
math: Move lerp function into SGMisc.
[simgear.git] / simgear / structure / event_mgr.hxx
index 5b31c8095bf168b8853f7bb6fe7b6607e917a4ff..b8dda323fb7e7c15f4ae3156a69b1d52b99702dc 100644 (file)
@@ -8,14 +8,16 @@
 
 class SGEventMgr;
 
-struct SGTimer {
+class SGTimer {
+public:
+    ~SGTimer();
+    void run();
+    
     std::string name;
     double interval;
     SGCallback* callback;
-    SGEventMgr* mgr;
     bool repeat;
-    bool simtime;
-    void run();
+    bool running;
 };
 
 class SGTimerQueue {
@@ -37,7 +39,7 @@ public:
     SGTimer* findByName(const std::string& name) const;
 private:
     // The "priority" is stored as a negative time.  This allows the
-    // implemenetation to treat the "top" of the heap as the largest
+    // implementation to treat the "top" of the heap as the largest
     // value and avoids developer mindbugs. ;)
     struct HeapEntry { double pri; SGTimer* timer; };
 
@@ -115,7 +117,7 @@ public:
 
     void removeTask(const std::string& name);
 private:
-    friend struct SGTimer;
+    friend class SGTimer;
 
     void add(const std::string& name, SGCallback* cb,
              double interval, double delay,