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

Unified Diff: Source/core/dom/Element.cpp

Issue 533963002: Don't fail the style assert in Element::rendererIsFocusable if the document is active. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix compile. Created 6 years, 3 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/web/WebLocalFrameImpl.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Element.cpp
diff --git a/Source/core/dom/Element.cpp b/Source/core/dom/Element.cpp
index 7f7a9a06ab6a6cc3ac920dbf1a2572a23eb3d8a8..04efa32033cf007e153f2f7d5487304d5665421c 100644
--- a/Source/core/dom/Element.cpp
+++ b/Source/core/dom/Element.cpp
@@ -237,7 +237,9 @@ bool Element::rendererIsFocusable() const
// We can't just use needsStyleRecalc() because if the node is in a
// display:none tree it might say it needs style recalc but the whole
// document is actually up to date.
- ASSERT(!document().childNeedsStyleRecalc());
+ // In addition, style cannot be cleared out for non-active documents,
+ // so in that case the childNeedsStyleRecalc check is invalid.
+ ASSERT(!document().isActive() || !document().childNeedsStyleRecalc());
}
// FIXME: Even if we are not visible, we might have a child that is visible.
« no previous file with comments | « no previous file | Source/web/WebLocalFrameImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698