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

Unified Diff: Source/core/dom/Document.h

Issue 465563002: Make onload async (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 4 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 | Source/core/dom/Document.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Document.h
diff --git a/Source/core/dom/Document.h b/Source/core/dom/Document.h
index a68d8782bbfe06f0d422d6835e929267e1d24ffb..c6e2f672c710886b0aedd5a592f942b78a6537d0 100644
--- a/Source/core/dom/Document.h
+++ b/Source/core/dom/Document.h
@@ -887,6 +887,7 @@ public:
enum LoadEventProgress {
LoadEventNotRun,
LoadEventTried,
+ LoadEventScheduled,
LoadEventInProgress,
LoadEventCompleted,
BeforeUnloadEventInProgress,
@@ -896,7 +897,7 @@ public:
UnloadEventHandled
};
bool loadEventStillNeeded() const { return m_loadEventProgress == LoadEventNotRun; }
- bool processingLoadEvent() const { return m_loadEventProgress == LoadEventInProgress; }
+ bool processingLoadEvent() const { return m_loadEventProgress == LoadEventScheduled || m_loadEventProgress == LoadEventInProgress; }
bool loadEventFinished() const { return m_loadEventProgress >= LoadEventCompleted; }
bool unloadStarted() const { return m_loadEventProgress >= PageHideInProgress; }
@@ -923,7 +924,7 @@ public:
// Used to allow element that loads data without going through a FrameLoader to delay the 'load' event.
void incrementLoadEventDelayCount() { ++m_loadEventDelayCount; }
void decrementLoadEventDelayCount();
- void checkLoadEventSoon();
+ void checkLoadEvent();
bool isDelayingLoadEvent();
void loadPluginsSoon();
@@ -1128,7 +1129,7 @@ private:
void executeScriptsWaitingForResourcesTimerFired(Timer<Document>*);
- void loadEventDelayTimerFired(Timer<Document>*);
+ void loadEventTimerFired(Timer<Document>*);
void pluginLoadingTimerFired(Timer<Document>*);
PageVisibilityState pageVisibilityState() const;
@@ -1329,7 +1330,7 @@ private:
WillBeHeapVector<RefPtrWillBeMember<Element> > m_topLayerElements;
int m_loadEventDelayCount;
- Timer<Document> m_loadEventDelayTimer;
+ Timer<Document> m_loadEventTimer;
Timer<Document> m_pluginLoadingTimer;
ViewportDescription m_viewportDescription;
« no previous file with comments | « no previous file | Source/core/dom/Document.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698