Bug 290469. Don't trust the offset returned by GetOffsetFromView. r+sr=bzbarsky,a=asa
git-svn-id: svn://10.0.0.236/trunk@172459 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
9c3f620600
commit
3b48266d9a
@ -6500,6 +6500,12 @@ nsBlockFrame::HandleEvent(nsPresContext* aPresContext,
|
||||
nsPoint viewOffset;
|
||||
nsIView* parentWithView;
|
||||
GetOffsetFromView(viewOffset, &parentWithView);
|
||||
// The offset returned by GetOffsetFromView is not trustworthy.
|
||||
// It's just the sum of frame positions and is not the true
|
||||
// geometric offset. So recalculate the true geometric offset.
|
||||
NS_ASSERTION(nsLayoutUtils::GetFrameFor(parentWithView),
|
||||
"GetOffsetFromView shouldn't be returning a frameless view");
|
||||
viewOffset = GetOffsetTo(nsLayoutUtils::GetFrameFor(parentWithView));
|
||||
|
||||
while(NS_OK == result)
|
||||
{ //we are starting aloop to allow us to "drill down to the one we want"
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user