Fix hang bug 232368. Patch by Mats Palmgren <mats.palmgren@bredband.net>,

r=bzbarsky, sr=bryner
This commit is contained in:
bzbarsky%mit.edu 2004-02-11 07:47:06 +00:00
Родитель 43b10e36e5
Коммит 4d40400018
1 изменённых файлов: 7 добавлений и 2 удалений

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

@ -3120,8 +3120,13 @@ nsEventStateManager::ShiftFocusInternal(PRBool aForward, nsIContent* aStart)
if (!mCurrentFocus && oldFocus) {
// ChangeFocus failed to move focus to nextFocus because a blur handler
// made it unfocusable. (bug #118685)
mCurrentTarget = nsnull;
return ShiftFocusInternal(aForward, oldFocus);
// Try again unless it's from the same point, bug 232368.
if (oldFocus != aStart) {
mCurrentTarget = nsnull;
return ShiftFocusInternal(aForward, oldFocus);
} else {
return NS_OK;
}
} else {
GetFocusedFrame(&mCurrentTarget);
if (mCurrentTarget)