Back out 7 changesets (bug 1177018) for debug b2g assertion failures in test_bug982141.html

CLOSED TREE

Backed out changeset 40fdd735520d (bug 1177018)
Backed out changeset a82c39bb97ab (bug 1177018)
Backed out changeset dbb14a5cd2cd (bug 1177018)
Backed out changeset 112ec6bdaf4e (bug 1177018)
Backed out changeset 486f9a11fcbd (bug 1177018)
Backed out changeset 8e54cc5e6901 (bug 1177018)
Backed out changeset c2a30b4f3a7c (bug 1177018)
This commit is contained in:
Phil Ringnalda 2015-08-26 21:38:05 -07:00
parent 0dc46f2604
commit a3cd9e9701
11 changed files with 27 additions and 71 deletions

View File

@ -634,14 +634,6 @@ child:
* they are 'compressed' by dumping the oldest one.
*/
RealMouseMoveEvent(WidgetMouseEvent event) compress;
/**
* Mouse move events with |reason == eSynthesized| are sent via a separate
* message because they do not generate DOM 'mousemove' events, and the
* 'compress' attribute on RealMouseMoveEvent() could result in a
* |reason == eReal| event being dropped in favour of an |eSynthesized|
* event, and thus a DOM 'mousemove' event to be lost.
*/
SynthMouseMoveEvent(WidgetMouseEvent event);
RealMouseButtonEvent(WidgetMouseEvent event);
RealKeyEvent(WidgetKeyboardEvent event, MaybeNativeKeyBinding keyBinding);
MouseWheelEvent(WidgetWheelEvent event, ScrollableLayerGuid aGuid, uint64_t aInputBlockId);

View File

@ -1856,12 +1856,6 @@ TabChild::RecvRealMouseMoveEvent(const WidgetMouseEvent& event)
return RecvRealMouseButtonEvent(event);
}
bool
TabChild::RecvSynthMouseMoveEvent(const WidgetMouseEvent& event)
{
return RecvRealMouseButtonEvent(event);
}
bool
TabChild::RecvRealMouseButtonEvent(const WidgetMouseEvent& event)
{

View File

@ -334,7 +334,6 @@ public:
const int32_t& aModifiers,
const bool& aIgnoreRootScrollFrame) override;
virtual bool RecvRealMouseMoveEvent(const mozilla::WidgetMouseEvent& event) override;
virtual bool RecvSynthMouseMoveEvent(const mozilla::WidgetMouseEvent& event) override;
virtual bool RecvRealMouseButtonEvent(const mozilla::WidgetMouseEvent& event) override;
virtual bool RecvRealDragEvent(const WidgetDragEvent& aEvent,
const uint32_t& aDragAction,

View File

@ -1381,11 +1381,7 @@ bool TabParent::SendRealMouseEvent(WidgetMouseEvent& event)
}
if (NS_MOUSE_MOVE == event.mMessage) {
if (event.reason == WidgetMouseEvent::eSynthesized) {
return SendSynthMouseMoveEvent(event);
} else {
return SendRealMouseMoveEvent(event);
}
return SendRealMouseMoveEvent(event);
}
return SendRealMouseButtonEvent(event);
}

View File

@ -40,7 +40,14 @@ window.onload = function() {
// Dropping the touch slop to 0 makes the tests easier to write because
// we can just do a one-pixel drag to get over the pan threshold rather
// than having to hard-code some larger value.
["apz.touch_start_tolerance", "0.0"]
["apz.touch_start_tolerance", "0.0"],
// The B2G emulator is hella slow, and needs more than 300ms to run the
// main-thread code that deals with layerizing subframes and running
// touch listeners. In my local runs this needs to be at least 1000.
// On try this sometimes needs to be as long as 8 seconds (bug 1176798)
// so we make it 15 seconds just to be extra safe.
["apz.content_response_timeout", "15000"]
]
}, testDone);
};

View File

@ -17,9 +17,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=1151663
// inside an iframe which means we have no control over the root APZC.
var w = null;
window.onload = function() {
SpecialPowers.pushPrefEnv({"set": [["apz.test.logging_enabled", true]]}, function() {
w = window.open("helper_bug1151663.html", "_blank");
});
w = window.open("helper_bug1151663.html", "_blank");
};
function finishTest() {

View File

@ -17,9 +17,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=982141
// inside an iframe which means we have no control over the root APZC.
var w = null;
window.onload = function() {
SpecialPowers.pushPrefEnv({"set": [["apz.test.logging_enabled", true]]}, function() {
w = window.open("helper_bug982141.html", "_blank");
});
w = window.open("helper_bug982141.html", "_blank");
};
function finishTest() {

View File

@ -14,8 +14,6 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=1173580
<style>
#container {
display: flex;
overflow: scroll;
height: 500px;
}
.outer-frame {
height: 500px;
@ -23,7 +21,7 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=1173580
flex-basis: 100%;
background: repeating-linear-gradient(#CCC, #CCC 100px, #BBB 100px, #BBB 200px);
}
#container-content {
#page-content {
height: 200%;
}
</style>
@ -44,11 +42,11 @@ https://bugzilla.mozilla.org/show_bug.cgi?id=1173580
</div>
<iframe id="outer3" class="outer-frame" src="helper_iframe1.html"></iframe>
<iframe id="outer4" class="outer-frame" src="helper_iframe2.html"></iframe>
<!-- The container-content div ensures 'container' is scrollable, so the
optimization that layerizes the primary async-scrollable frame on page
load layerizes it rather than its child subframes. -->
<div id="container-content"></div>
</div>
<!-- The page-content div ensures the page is scrollable, so none of the
subframes are layerized by the optimization that layerizes the
primary async-scrollable frame on page load. -->
<div id="page-content"></div>
<pre id="test">
<script type="application/javascript;version=1.7">
@ -150,18 +148,8 @@ function startTest() {
}
SimpleTest.waitForExplicitFinish();
SimpleTest.testInChaosMode();
SimpleTest.waitForFocus(startTest, window);
// Disable smooth scrolling, because it results in long-running scroll
// animations that can result in a 'scroll' event triggered by an earlier
// wheel event as corresponding to a later wheel event.
// Also enable APZ test logging, since we use that data to determine whether
// a scroll frame was layerized.
SpecialPowers.pushPrefEnv({"set": [["general.smoothScroll", false],
["apz.test.logging_enabled", true]]},
function() {
SimpleTest.waitForFocus(startTest, window);
});
</script>
</pre>
</body>

View File

@ -176,7 +176,7 @@ private:
DECL_GFX_PREF(Live, "apz.pan_repaint_interval", APZPanRepaintInterval, int32_t, 250);
DECL_GFX_PREF(Live, "apz.printtree", APZPrintTree, bool, false);
DECL_GFX_PREF(Live, "apz.smooth_scroll_repaint_interval", APZSmoothScrollRepaintInterval, int32_t, 75);
DECL_GFX_PREF(Live, "apz.test.logging_enabled", APZTestLoggingEnabled, bool, false);
DECL_GFX_PREF(Once, "apz.test.logging_enabled", APZTestLoggingEnabled, bool, false);
DECL_GFX_PREF(Live, "apz.touch_start_tolerance", APZTouchStartTolerance, float, 1.0f/4.5f);
DECL_GFX_PREF(Live, "apz.use_paint_duration", APZUsePaintDuration, bool, true);
DECL_GFX_PREF(Live, "apz.velocity_bias", APZVelocityBias, float, 1.0f);

View File

@ -446,8 +446,13 @@ public:
*/
already_AddRefed<ImageContainer> GetContainerForImageLayer(nsDisplayListBuilder* aBuilder);
bool VisibleAboveRegionIntersects(const nsIntRect& aRect) const
{ return mVisibleAboveRegion.Intersects(aRect); }
bool VisibleAboveRegionIntersects(const nsIntRegion& aRegion) const
{ return !mVisibleAboveRegion.Intersect(aRegion).IsEmpty(); }
bool VisibleRegionIntersects(const nsIntRect& aRect) const
{ return mVisibleRegion.Intersects(aRect); }
bool VisibleRegionIntersects(const nsIntRegion& aRegion) const
{ return !mVisibleRegion.Intersect(aRegion).IsEmpty(); }
@ -1083,13 +1088,6 @@ public:
nsIFrame* GetContainerFrame() const { return mContainerFrame; }
nsDisplayListBuilder* Builder() const { return mBuilder; }
/**
* Check if we are currently inside an inactive layer.
*/
bool IsInInactiveLayer() const {
return mLayerBuilder->GetContainingPaintedLayerData();
}
/**
* Sets aOuterVisibleRegion as aLayer's visible region. aOuterVisibleRegion
* is in the coordinate space of the container reference frame.
@ -2586,22 +2584,12 @@ PaintedLayerDataNode::FindPaintedLayerFor(const nsIntRect& aVisibleRect,
} else {
PaintedLayerData* lowestUsableLayer = nullptr;
for (auto& data : Reversed(mPaintedLayerDataStack)) {
if (data.mVisibleAboveRegion.Intersects(aVisibleRect)) {
if (data.VisibleAboveRegionIntersects(aVisibleRect)) {
break;
}
MOZ_ASSERT(!data.mExclusiveToOneItem);
lowestUsableLayer = &data;
nsIntRegion visibleRegion = data.mVisibleRegion;
// When checking whether the visible region intersects the given
// visible rect, also include the event-regions in the visible region,
// unless we're in an inactive layer, in which case the event-regions
// will be hoisted out into their own layer.
ContainerState& contState = mTree.ContState();
if (!contState.IsInInactiveLayer()) {
visibleRegion.OrWith(contState.ScaleRegionToOutsidePixels(data.mHitRegion));
visibleRegion.OrWith(contState.ScaleRegionToOutsidePixels(data.mMaybeHitRegion));
}
if (visibleRegion.Intersects(aVisibleRect)) {
if (data.VisibleRegionIntersects(aVisibleRect)) {
break;
}
}

View File

@ -252,12 +252,8 @@ user_pref("identity.fxaccounts.remote.signin.uri", "https://%(server)s/fxa-signi
user_pref("identity.fxaccounts.settings.uri", "https://%(server)s/fxa-settings");
user_pref('identity.fxaccounts.remote.webchannel.uri', 'https://%(server)s/');
// Increase the APZ content response timeout in tests to 15 seconds.
// This is to accommodate the fact that test environments tends to be slower
// than production environments (with the b2g emulator being the slowest of them
// all), resulting in the production timeout value sometimes being exceeded
// and causing false-positive test failures. See bug 1176798, bug 1177018.
user_pref("apz.content_response_timeout", 15000);
// Enable logging of APZ test data (see bug 961289).
user_pref('apz.test.logging_enabled', true);
// Make sure SSL Error reports don't hit the network
user_pref("security.ssl.errorReporting.url", "https://example.com/browser/browser/base/content/test/general/pinning_reports.sjs?succeed");