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

Unified Diff: Source/core/html/parser/HTMLParserScheduler.h

Issue 876623002: Adds a CancellableTaskFactory and exposes postLoadingTasks to Blink (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Bundle in the HTML Parser changes too Created 5 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
Index: Source/core/html/parser/HTMLParserScheduler.h
diff --git a/Source/core/html/parser/HTMLParserScheduler.h b/Source/core/html/parser/HTMLParserScheduler.h
index d8d73fe7408a34e48f804e3584ca55a12c477dd3..1127f88dc01c60398fa6364e991697dd60ab05d5 100644
--- a/Source/core/html/parser/HTMLParserScheduler.h
+++ b/Source/core/html/parser/HTMLParserScheduler.h
@@ -27,7 +27,7 @@
#define HTMLParserScheduler_h
#include "core/html/parser/NestingLevelIncrementer.h"
-#include "platform/Timer.h"
+#include "platform/scheduler/CancellableTaskFactory.h"
#include "wtf/PassOwnPtr.h"
#include "wtf/RefPtr.h"
@@ -76,7 +76,7 @@ public:
}
~HTMLParserScheduler();
- bool isScheduledForResume() const { return m_isSuspendedWithActiveTimer || m_continueNextChunkTimer.isActive(); }
+ bool isScheduledForResume() const { return m_isSuspendedWithActiveTimer || m_cancelableContinueParse.isPending(); }
void scheduleForResume();
bool yieldIfNeeded(const SpeculationsPumpSession&, bool startingScript);
@@ -97,11 +97,10 @@ private:
explicit HTMLParserScheduler(HTMLDocumentParser*);
bool shouldYield(const SpeculationsPumpSession&, bool startingScript) const;
- void continueNextChunkTimerFired(Timer<HTMLParserScheduler>*);
HTMLDocumentParser* m_parser;
- Timer<HTMLParserScheduler> m_continueNextChunkTimer;
+ CancellableTaskFactory m_cancelableContinueParse;
Sami 2015/01/26 17:18:34 s/cancelable/cancellable/ (or the other way around
alex clarke (OOO till 29th) 2015/01/26 17:31:35 Done.
bool m_isSuspendedWithActiveTimer;
};

Powered by Google App Engine
This is Rietveld 408576698