]> git.mxchange.org Git - flightgear.git/commitdiff
Reset: TimeManager can be unbound.
authorJames Turner <zakalawe@mac.com>
Sun, 6 Oct 2013 16:33:42 +0000 (17:33 +0100)
committerJames Turner <zakalawe@mac.com>
Tue, 29 Oct 2013 23:01:58 +0000 (23:01 +0000)
src/Time/TimeManager.cxx
src/Time/TimeManager.hxx

index 9fdca4c99e1da2a198dd5840c45347370f83d9b6..36312b532aecefb904d41fe9934a7377c874d6ef 100644 (file)
@@ -108,6 +108,20 @@ void TimeManager::init()
   _frameCount = 0;
 }
 
+void TimeManager::unbind()
+{
+    _maxDtPerFrame.clear();
+    _clockFreeze.clear();
+    _timeOverride.clear();
+    _warp.clear();
+    _warpDelta.clear();
+    _frameRate.clear();
+    _frameLatency.clear();
+    _frameRateWorst.clear();
+    
+    // and the property objects too
+}
+
 void TimeManager::postinit()
 {
   initTimeOffset();
index 9eb40980be2f013f8b0da1d59fa036928edec194..46d3f9ed632d88972f11ecda20e5ea5917a55012 100644 (file)
@@ -40,6 +40,8 @@ public:
   virtual void postinit();
   virtual void shutdown();
   
+  virtual void unbind();
+    
   void update(double dt);
   
 // SGPropertyChangeListener overrides