Bug 296803. Don't start list item selection prematurely when the combobox pops up above the select control. r+sr=me, patch by Jan Darmochwal, a=asa

This commit is contained in:
roc+%cs.cmu.edu 2005-06-14 22:15:53 +00:00
parent e4f44c2ee7
commit d960828b32

View File

@ -2525,7 +2525,8 @@ nsListControlFrame::UpdateInListState(nsIDOMEvent* aEvent)
return;
nsPoint pt = nsLayoutUtils::GetDOMEventCoordinatesRelativeTo(aEvent, this);
if (pt.y >= GetScrollableView()->View()->GetBounds().y) {
nsRect borderInnerEdge = GetScrollableView()->View()->GetBounds();
if (pt.y >= borderInnerEdge.y && pt.y < borderInnerEdge.YMost()) {
mItemSelectionStarted = PR_TRUE;
}
}