Fix revokeEvents to reliably revoke them. Bug 284389, r=darin, sr=dbaron,

a=asa


git-svn-id: svn://10.0.0.236/trunk@172263 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
bzbarsky%mit.edu
2005-04-15 03:17:13 +00:00
parent 2cb741be2f
commit ca0e40385d
5 changed files with 31 additions and 17 deletions

View File

@@ -358,14 +358,6 @@ static void* PR_CALLBACK HandlePLEvent(PLEvent* aEvent)
NS_ASSERTION(nsnull != aEvent,"Event is null");
nsViewManagerEvent *event = NS_STATIC_CAST(nsViewManagerEvent*, aEvent);
// Search for valid view manager before trying to access it. This
// is working around a bug in RevokeEvents.
const nsVoidArray *vmArray = nsViewManager::GetViewManagerArray();
if (!vmArray || vmArray->IndexOf(event->ViewManager()) == -1) {
NS_ERROR("RevokeEvents is buggy. Fix it!");
return nsnull;
}
event->HandleEvent();
return nsnull;
}