r=vidur. Fix for bug . We now revoke pending reflow events in the pres shell's destructor.
git-svn-id: svn://10.0.0.236/trunk@60301 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -715,6 +715,12 @@ PresShell::~PresShell()
|
||||
mViewEventListener->SetPresShell((nsIPresShell*)nsnull);
|
||||
NS_RELEASE(mViewEventListener);
|
||||
}
|
||||
|
||||
// Revoke pending reflow events
|
||||
if (mPendingReflowEvent) {
|
||||
mPendingReflowEvent = PR_FALSE;
|
||||
mEventQueue->RevokeEvents(this);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1875,7 +1881,7 @@ ReflowEvent::ReflowEvent(nsIPresShell* aPresShell, nsIEventQueue* aQueue)
|
||||
|
||||
mPresShell = getter_AddRefs(NS_GetWeakReference(aPresShell));
|
||||
|
||||
PL_InitEvent(this, nsnull,
|
||||
PL_InitEvent(this, aPresShell,
|
||||
(PLHandleEventProc) ::HandlePLEvent,
|
||||
(PLDestroyEventProc) ::DestroyPLEvent);
|
||||
|
||||
|
||||
@@ -715,6 +715,12 @@ PresShell::~PresShell()
|
||||
mViewEventListener->SetPresShell((nsIPresShell*)nsnull);
|
||||
NS_RELEASE(mViewEventListener);
|
||||
}
|
||||
|
||||
// Revoke pending reflow events
|
||||
if (mPendingReflowEvent) {
|
||||
mPendingReflowEvent = PR_FALSE;
|
||||
mEventQueue->RevokeEvents(this);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -1875,7 +1881,7 @@ ReflowEvent::ReflowEvent(nsIPresShell* aPresShell, nsIEventQueue* aQueue)
|
||||
|
||||
mPresShell = getter_AddRefs(NS_GetWeakReference(aPresShell));
|
||||
|
||||
PL_InitEvent(this, nsnull,
|
||||
PL_InitEvent(this, aPresShell,
|
||||
(PLHandleEventProc) ::HandlePLEvent,
|
||||
(PLDestroyEventProc) ::DestroyPLEvent);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user