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:
@@ -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;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user