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

Unified Diff: content/gpu/gpu_watchdog_thread.h

Issue 6463013: Add support for base::Closure in the MessageLoop. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/base
Patch Set: address will's comments. Created 9 years, 9 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
Index: content/gpu/gpu_watchdog_thread.h
diff --git a/content/gpu/gpu_watchdog_thread.h b/content/gpu/gpu_watchdog_thread.h
index b0812a64d196dee5ca018ceeddd5fb5e84975e5f..fcf1b58b68e5a0a1a3e30fd597917dba5229c50a 100644
--- a/content/gpu/gpu_watchdog_thread.h
+++ b/content/gpu/gpu_watchdog_thread.h
@@ -32,14 +32,14 @@ class GpuWatchdogThread : public base::Thread,
// An object of this type intercepts the reception and completion of all tasks
// on the watched thread and checks whether the watchdog is armed.
- class GpuWatchdogTaskObserver : public MessageLoop::TaskObserver {
+ class GpuWatchdogClosureObserver : public MessageLoop::ClosureObserver {
public:
- explicit GpuWatchdogTaskObserver(GpuWatchdogThread* watchdog);
- virtual ~GpuWatchdogTaskObserver();
+ explicit GpuWatchdogClosureObserver(GpuWatchdogThread* watchdog);
+ virtual ~GpuWatchdogClosureObserver();
- // Implements MessageLoop::TaskObserver.
- virtual void WillProcessTask(const Task* task);
- virtual void DidProcessTask(const Task* task);
+ // Implements MessageLoop::ClosureObserver.
+ virtual void WillProcessClosure(base::TimeTicks time_posted) OVERRIDE;
+ virtual void DidProcessClosure(base::TimeTicks time_posted) OVERRIDE;
private:
void CheckArmed();
@@ -56,7 +56,7 @@ class GpuWatchdogThread : public base::Thread,
MessageLoop* watched_message_loop_;
int timeout_;
volatile bool armed_;
- GpuWatchdogTaskObserver task_observer_;
+ GpuWatchdogClosureObserver closure_observer_;
#if defined(OS_WIN)
void* watched_thread_handle_;

Powered by Google App Engine
This is Rietveld 408576698