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

Unified Diff: Source/core/css/MediaQueryMatcher.cpp

Issue 368533003: Revert of Call media query change listeners asynchronously. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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 | « Source/core/css/MediaQueryListListener.cpp ('k') | Source/core/dom/Document.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/MediaQueryMatcher.cpp
diff --git a/Source/core/css/MediaQueryMatcher.cpp b/Source/core/css/MediaQueryMatcher.cpp
index d50048fd76a55264e382cf5285fe83dc7df53903..c9e748ea306699aa06658f8c756d77aa2e86f90d 100644
--- a/Source/core/css/MediaQueryMatcher.cpp
+++ b/Source/core/css/MediaQueryMatcher.cpp
@@ -109,7 +109,9 @@
for (MediaQueryListSet::iterator it = m_mediaLists.begin(); it != m_mediaLists.end(); ++it)
(*it)->mediaFeaturesChanged(&listenersToNotify);
- m_document->enqueueMediaQueryChangeListeners(listenersToNotify);
+ // FIXME: This should be async! We're running script inside ::layout() or ::updateRenderTree().
+ for (size_t i = 0; i < listenersToNotify.size(); ++i)
+ listenersToNotify[i]->call();
}
void MediaQueryMatcher::trace(Visitor* visitor)
« no previous file with comments | « Source/core/css/MediaQueryListListener.cpp ('k') | Source/core/dom/Document.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698