]> git.saurik.com Git - wxWidgets.git/commitdiff
Add warning if wxStopWatch is up to second resolution
authorSylvain Bougnoux <bougnoux@imra-europe.com>
Wed, 2 Feb 2000 16:37:56 +0000 (16:37 +0000)
committerSylvain Bougnoux <bougnoux@imra-europe.com>
Wed, 2 Feb 2000 16:37:56 +0000 (16:37 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@5800 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

src/common/timercmn.cpp

index 64dbb0aac2bcdcad7be03199feec4536dafc1082..15d1abc07eea8280d6d7968831c11649bf9ad3d7 100644 (file)
@@ -89,14 +89,14 @@ void wxStopWatch::Start(long t)
     m_pause = 0;
 }
 
-long wxStopWatch::Time() const
+inline long wxStopWatch::GetElapsedTime() const
 {
-    return (m_pause ? m_pause : GetElapsedTime());
+    return (wxGetLocalTimeMillis() - m_t0).GetLo();
 }
 
-long wxStopWatch::GetElapsedTime() const
+long wxStopWatch::Time() const
 {
-    return (wxGetLocalTimeMillis() - m_t0).GetLo();
+    return (m_pause ? m_pause : GetElapsedTime());
 }
 
 // ----------------------------------------------------------------------------
@@ -233,6 +233,8 @@ wxLongLong wxGetLocalTimeMillis()
     {
         return (val + tp.millitm);
     }
+#else
+#warning "wxStopWatch will be up to second resolution!"
 #endif
 
     return val;