Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(70)

Unified Diff: cc/timer.h

Issue 11122003: [cc] Rename all cc/ filenames to Chromium style (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/time_source.h ('k') | cc/timer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/timer.h
diff --git a/cc/timer.h b/cc/timer.h
index 638cbb270ce9b24689d5095baf174ade4f4d1a13..9424aef99d48ebec930e924abcce09cda6489f91 100644
--- a/cc/timer.h
+++ b/cc/timer.h
@@ -1,3 +1,41 @@
-// Copyright 2012 The Chromium Authors. All rights reserved.
+// Copyright 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+
+#ifndef CCTimer_h
+#define CCTimer_h
+
+namespace cc {
+
+class CCThread;
+class CCTimerTask;
+
+class CCTimerClient {
+public:
+ virtual ~CCTimerClient() { }
+
+ virtual void onTimerFired() = 0;
+};
+
+class CCTimer {
+public:
+ CCTimer(CCThread*, CCTimerClient*);
+ ~CCTimer();
+
+ // If a previous task is pending, it will be replaced with the new one.
+ void startOneShot(double intervalSeconds);
+ void stop();
+
+ bool isActive() const { return m_task; }
+
+private:
+ friend class CCTimerTask;
+
+ CCTimerClient* m_client;
+ CCThread* m_thread;
+ CCTimerTask* m_task; // weak pointer
+};
+
+} // namespace cc
+
+#endif
« no previous file with comments | « cc/time_source.h ('k') | cc/timer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698