This patch includes the earlier two patches, with roc's nit in comment 7.
Additionally,
1. add "StopAutoScrollTimer()" in DisconnectFromPresShell(), this will
Cancel an outstanding timer and is necessary since it uses a raw
pres context pointer (and other pointers) which could be stale.
2. use nsWeakView in UpdateWidgetsForView() to detect view destruction
3. keep strong refs on the pres shell and view manager over the
viewManager->Composite() call, and give up if presShell->IsDestroying()
after it.
I have high hopes for the UpdateWidgetsForView() fix - I think that's
a bug I've been hunting for years...
Tested on Linux, MacOSX and XP. There are still a few assertions for
the first testcase, but nothing too serious, they can be fixed separately.
Created attachment 346918
Patch rev. 2
[Checkin: Comment 18 & 19]
This patch includes the earlier two patches, with roc's nit in comment 7.
Additionally, Timer() " in DisconnectFromP resShell( ), this will rView() to detect view destruction >Composite( ) call, and give up if presShell- >IsDestroying( )
1. add "StopAutoScroll
Cancel an outstanding timer and is necessary since it uses a raw
pres context pointer (and other pointers) which could be stale.
2. use nsWeakView in UpdateWidgetsFo
3. keep strong refs on the pres shell and view manager over the
viewManager-
after it.
I have high hopes for the UpdateWidgetsFo rView() fix - I think that's
a bug I've been hunting for years...
Tested on Linux, MacOSX and XP. There are still a few assertions for
the first testcase, but nothing too serious, they can be fixed separately.