Bug 1552608 - Remove the 'aNode' parameter of GetAPZCAtPoint(). r=tnikkel

This is a relic from earlier times when GetAPZCAtPoint() was recursive.

Differential Revision: https://phabricator.services.mozilla.com/D48380

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Botond Ballo 2019-10-07 22:00:59 +00:00
parent f8900bc22d
commit 9649f2e747
2 changed files with 5 additions and 7 deletions

View File

@ -2588,8 +2588,7 @@ already_AddRefed<AsyncPanZoomController> APZCTreeManager::GetTargetAPZC(
if (gfx::gfxVars::UseWebRender()) {
target = GetAPZCAtPointWR(aPoint, &hitResult, aOutLayersId, &scrollbarNode);
} else {
target = GetAPZCAtPoint(mRootNode, aPoint, &hitResult, aOutLayersId,
&scrollbarNode);
target = GetAPZCAtPoint(aPoint, &hitResult, aOutLayersId, &scrollbarNode);
}
if (aOutHitResult) {
@ -2778,15 +2777,14 @@ AsyncPanZoomController* APZCTreeManager::GetTargetApzcForNode(
}
AsyncPanZoomController* APZCTreeManager::GetAPZCAtPoint(
HitTestingTreeNode* aNode, const ScreenPoint& aHitTestPoint,
CompositorHitTestInfo* aOutHitResult, LayersId* aOutLayersId,
HitTestingTreeNode** aOutScrollbarNode) {
const ScreenPoint& aHitTestPoint, CompositorHitTestInfo* aOutHitResult,
LayersId* aOutLayersId, HitTestingTreeNode** aOutScrollbarNode) {
mTreeLock.AssertCurrentThreadIn();
// This walks the tree in depth-first, reverse order, so that it encounters
// APZCs front-to-back on the screen.
HitTestingTreeNode* resultNode;
HitTestingTreeNode* root = aNode;
HitTestingTreeNode* root = mRootNode;
std::stack<LayerPoint> hitTestPoints;
ParentLayerPoint point = ViewAs<ParentLayerPixel>(
aHitTestPoint, PixelCastJustification::ScreenIsParentLayerForRoot);

View File

@ -615,7 +615,7 @@ class APZCTreeManager : public IAPZCTreeManager, public APZInputBridge {
GuidComparator aComparator);
AsyncPanZoomController* GetTargetApzcForNode(HitTestingTreeNode* aNode);
AsyncPanZoomController* GetAPZCAtPoint(
HitTestingTreeNode* aNode, const ScreenPoint& aHitTestPoint,
const ScreenPoint& aHitTestPoint,
gfx::CompositorHitTestInfo* aOutHitResult, LayersId* aOutLayersId,
HitTestingTreeNode** aOutScrollbarNode);
already_AddRefed<AsyncPanZoomController> GetAPZCAtPointWR(