mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-28 05:10:49 +00:00

The change to GetAfterFrameForContent prevents the reframe that is part of the chain of events leading to this bug, and thus fixes the bug on its own. The change to GetBeforeFrameForContent seems desirable for symmetry. Note that patch 6 also independently fixes the reported bug. This probably needs somewhat careful review. We should examine: (1) what the rules for calling nsLayoutUtils::GetBeforeFrame and nsLayoutUtils::GetAfterFrame are, and whether both (or neither) need to be patched. (2) What the rules are for which frame the GenConProperty() lives on, and whether we should adjust nsIFrame::GetGenConPseudos() to either do something more intelligent, or assert about callers. (We should probably clean up some of these things in a followup bug.) Since the symptom of this bug is (once patch 4 is in the tree) only causing extra reframes, it can only be tested using the new API (from bug 1115691) for observing reframes. I confirmed that the test for this bug fails without the patch and passes with the patch (as noted by the removal of its todo annotation). This patch fixes the assertion on layout/generic/crashtests/600100.xhtml, though I haven't investigated why.