Index: Source/WebCore/dom/Document.cpp |
=================================================================== |
--- Source/WebCore/dom/Document.cpp (revision 126674) |
+++ Source/WebCore/dom/Document.cpp (working copy) |
@@ -553,6 +553,7 @@ |
m_hasDirtyStyleResolver = false; |
m_pendingStylesheets = 0; |
m_ignorePendingStylesheets = false; |
+ m_needsNotifyRemoveAllPendingStylesheet = false; |
m_hasNodesWithPlaceholderStyle = false; |
m_pendingSheetLayout = NoLayoutWithPendingSheets; |
@@ -3313,7 +3314,7 @@ |
} |
// This method is called whenever a top-level stylesheet has finished loading. |
-void Document::removePendingSheet() |
+void Document::removePendingSheet(RemovePendingSheetNotificationType notification) |
{ |
// Make sure we knew this sheet was pending, and that our count isn't out of sync. |
ASSERT(m_pendingStylesheets > 0); |
@@ -3328,6 +3329,18 @@ |
if (m_pendingStylesheets) |
return; |
+ if (notification == RemovePendingSheetNotifyLater) { |
+ setNeedsNotifyRemoveAllPendingStylesheet(); |
+ return; |
+ } |
+ |
+ didRemoveAllPendingStylesheet(); |
+} |
+ |
+void Document::didRemoveAllPendingStylesheet() |
+{ |
+ m_needsNotifyRemoveAllPendingStylesheet = false; |
+ |
styleResolverChanged(RecalcStyleIfNeeded); |
if (ScriptableDocumentParser* parser = scriptableDocumentParser()) |
@@ -3337,6 +3350,7 @@ |
view()->scrollToFragment(m_url); |
} |
+ |
void Document::evaluateMediaQueryList() |
{ |
if (m_mediaQueryMatcher) |