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

Unified Diff: third_party/WebKit/Source/web/WebLeakDetector.cpp

Issue 2644963003: Move WebLeakDetectorImpl to TaskRunnerTimer. (Closed)
Patch Set: Created 3 years, 11 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/web/WebLeakDetector.cpp
diff --git a/third_party/WebKit/Source/web/WebLeakDetector.cpp b/third_party/WebKit/Source/web/WebLeakDetector.cpp
index 755a7640a1b2c40cd5ce1c2bb3662bf0d8f06fcf..9775d1fc773dd84caff544ddf47fd1d77765bb27 100644
--- a/third_party/WebKit/Source/web/WebLeakDetector.cpp
+++ b/third_party/WebKit/Source/web/WebLeakDetector.cpp
@@ -39,6 +39,8 @@
#include "modules/compositorworker/AbstractAnimationWorkletThread.h"
#include "platform/InstanceCounters.h"
#include "platform/Timer.h"
+#include "public/platform/Platform.h"
+#include "public/platform/WebThread.h"
#include "public/web/WebFrame.h"
#include "web/WebLocalFrameImpl.h"
@@ -52,9 +54,14 @@ class WebLeakDetectorImpl final : public WebLeakDetector {
public:
explicit WebLeakDetectorImpl(WebLeakDetectorClient* client)
: m_client(client),
- m_delayedGCAndReportTimer(this,
- &WebLeakDetectorImpl::delayedGCAndReport),
- m_delayedReportTimer(this, &WebLeakDetectorImpl::delayedReport),
+ m_delayedGCAndReportTimer(
+ Platform::current()->currentThread()->getWebTaskRunner(),
+ this,
+ &WebLeakDetectorImpl::delayedGCAndReport),
+ m_delayedReportTimer(
+ Platform::current()->currentThread()->getWebTaskRunner(),
+ this,
+ &WebLeakDetectorImpl::delayedReport),
m_numberOfGCNeeded(0) {
DCHECK(m_client);
}
@@ -69,8 +76,8 @@ class WebLeakDetectorImpl final : public WebLeakDetector {
void delayedReport(TimerBase*);
WebLeakDetectorClient* m_client;
- Timer<WebLeakDetectorImpl> m_delayedGCAndReportTimer;
- Timer<WebLeakDetectorImpl> m_delayedReportTimer;
+ TaskRunnerTimer<WebLeakDetectorImpl> m_delayedGCAndReportTimer;
+ TaskRunnerTimer<WebLeakDetectorImpl> m_delayedReportTimer;
int m_numberOfGCNeeded;
};
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698