Bug 291443. Capture the mouse if the user clicks on an item in a showed drop-down list. r+sr=bzbarsky,a=asa

This commit is contained in:
roc+%cs.cmu.edu 2005-07-10 23:46:56 +00:00
Родитель adabaec0ce
Коммит e7fe85d510
1 изменённых файлов: 3 добавлений и 5 удалений

Просмотреть файл

@ -2705,11 +2705,9 @@ nsListControlFrame::MouseDown(nsIDOMEvent* aMouseEvent)
PRInt32 selectedIndex;
if (NS_SUCCEEDED(GetIndexFromDOMEvent(aMouseEvent, selectedIndex))) {
if (!IsInDropDownMode()) {
// Handle Like List
CaptureMouseEvents(GetPresContext(), PR_TRUE);
mChangesSinceDragStart = HandleListSelection(aMouseEvent, selectedIndex);
}
// Handle Like List
CaptureMouseEvents(GetPresContext(), PR_TRUE);
mChangesSinceDragStart = HandleListSelection(aMouseEvent, selectedIndex);
} else {
// NOTE: the combo box is responsible for dropping it down
if (mComboboxFrame) {