Bug 580834. Make nsLayoutUtils::GetActiveScrolledRoot stop at the nearest popup ancestor instead of asserting. r=tnikkel,a=dbaron
authorRobert O'Callahan <robert@ocallahan.org>
Fri, 13 Aug 2010 22:03:51 +1200
changeset 50412 29114207a571a20bdeda7a2e1eb6131ba5b86076
parent 50411 19c6914ca8cd12fa8e5be4aca6ae211524ca0018
child 50413 3137ecdfdb608520f0801a8fb1ec8739ca4d4539
push id1
push userroot
push dateTue, 26 Apr 2011 22:38:44 +0000
treeherdermozilla-beta@bfdb6e623a36 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstnikkel, dbaron
bugs580834
milestone2.0b4pre
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 580834. Make nsLayoutUtils::GetActiveScrolledRoot stop at the nearest popup ancestor instead of asserting. r=tnikkel,a=dbaron
layout/base/crashtests/580834-1.xhtml
layout/base/crashtests/crashtests.list
layout/base/nsLayoutUtils.cpp
new file mode 100644
--- /dev/null
+++ b/layout/base/crashtests/580834-1.xhtml
@@ -0,0 +1,5 @@
+<html xmlns="http://www.w3.org/1999/xhtml">
+<body>
+<menuitem xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"><tooltip/><vbox xmlns="http://www.w3.org/1999/xhtml"></vbox></menuitem>
+</body>
+</html>
--- a/layout/base/crashtests/crashtests.list
+++ b/layout/base/crashtests/crashtests.list
@@ -301,8 +301,9 @@ load 541869-2.html
 load 560441-1.xhtml
 load 560447-1.html
 load 564063-1.html
 load 567292-1.xhtml
 load 569018-1.html
 load 572003.xul
 load 572582-1.xhtml
 load 580494-1.html
+load 580834-1.xhtml
--- a/layout/base/nsLayoutUtils.cpp
+++ b/layout/base/nsLayoutUtils.cpp
@@ -680,17 +680,18 @@ nsLayoutUtils::GetScrollableFrameFor(nsI
 }
 
 nsIFrame*
 nsLayoutUtils::GetActiveScrolledRootFor(nsIFrame* aFrame,
                                         nsIFrame* aStopAtAncestor)
 {
   nsIFrame* f = aFrame;
   while (f != aStopAtAncestor) {
-    NS_ASSERTION(!IsPopup(f), "Should have stopped before popup");
+    if (IsPopup(f))
+      break;
     nsIFrame* parent = GetCrossDocParentFrame(f);
     if (!parent)
       break;
     nsIScrollableFrame* sf = do_QueryFrame(parent);
     if (sf && sf->IsScrollingActive() && sf->GetScrolledFrame() == f)
       break;
     f = parent;
   }