Index: third_party/WebKit/Source/platform/Timer.h |
diff --git a/third_party/WebKit/Source/platform/Timer.h b/third_party/WebKit/Source/platform/Timer.h |
index 0a9503f9e72360f70b0496b8b135b01f46b5a61b..8245b3adbf1a499f5fbfa49ee5816444badc9fcf 100644 |
--- a/third_party/WebKit/Source/platform/Timer.h |
+++ b/third_party/WebKit/Source/platform/Timer.h |
@@ -159,11 +159,18 @@ class Timer : public TimerBase { |
public: |
using TimerFiredFunction = void (TimerFiredClass::*)(Timer<TimerFiredClass>*); |
+ // TODO(dcheng): Consider removing this overload once all timers are using the |
+ // appropriate task runner. https://crbug.com/624694 |
Timer(TimerFiredClass* o, TimerFiredFunction f) |
: m_object(o), m_function(f) |
{ |
} |
+ Timer(TimerFiredClass* o, TimerFiredFunction f, WebTaskRunner* webTaskRunner) |
+ : TimerBase(webTaskRunner), m_object(o), m_function(f) |
+ { |
+ } |
+ |
~Timer() override { } |
protected: |
@@ -181,11 +188,6 @@ protected: |
return TimerIsObjectAliveTrait<TimerFiredClass>::isHeapObjectAlive(m_object); |
} |
- Timer(TimerFiredClass* o, TimerFiredFunction f, WebTaskRunner* webTaskRunner) |
- : TimerBase(webTaskRunner), m_object(o), m_function(f) |
- { |
- } |
- |
private: |
// FIXME: Oilpan: TimerBase should be moved to the heap and m_object should be traced. |
// This raw pointer is safe as long as Timer<X> is held by the X itself (That's the case |