happen when the toplevel window is beign destroyed but a decendent
window (child, grandchild...) has an EVT_KILL_FOCUS handler that does
some drawing or other significant work.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@27795
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
if ( y ) pt.y = *y ;
if ( !IsTopLevel() )
- HIViewConvertPoint( &pt , *m_peer , (ControlRef) MacGetTopLevelWindow()->GetHandle() ) ;
+ {
+ wxTopLevelWindowMac* top = MacGetTopLevelWindow();
+ if (top)
+ HIViewConvertPoint( &pt , *m_peer , (ControlRef) top->GetHandle() ) ;
+ }
if ( x ) *x = (int) pt.x ;
if ( y ) *y = (int) pt.y ;