mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-03-05 16:22:53 +00:00
Fixed #3154 "Events don't work with fixed positioning". Fixed "clicks in vScrollBar down arrow are ignored".
This commit is contained in:
parent
f1548249dd
commit
515de5dbaf
@ -1120,14 +1120,15 @@ PRBool nsWindow::PointInWidget(Point aThePoint)
|
||||
//-------------------------------------------------------------------------
|
||||
nsWindow* nsWindow::FindWidgetHit(Point aThePoint)
|
||||
{
|
||||
if (! PointInWidget(aThePoint))
|
||||
if (!mVisible || !PointInWidget(aThePoint))
|
||||
return nsnull;
|
||||
|
||||
nsWindow* widgetHit = this;
|
||||
nsIEnumerator* children = GetChildren();
|
||||
if (children)
|
||||
{
|
||||
children->First();
|
||||
// traverse through all the nsWindows to find out who got hit, lowest level of course
|
||||
children->Last();
|
||||
do
|
||||
{
|
||||
nsISupports* child;
|
||||
@ -1143,7 +1144,7 @@ nsWindow* nsWindow::FindWidgetHit(Point aThePoint)
|
||||
NS_RELEASE(child);
|
||||
}
|
||||
}
|
||||
while (NS_SUCCEEDED(children->Next()));
|
||||
while (NS_SUCCEEDED(children->Prev()));
|
||||
NS_RELEASE(children);
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user