fixing layering problems when modal dialogs should appear in front of floating windows (eg miniframes), as long as wxSTAY_ON_TOP is not set on the miniframe
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_8_BRANCH@47699 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -146,7 +146,10 @@ void wxDialog::DoShowModal()
|
|||||||
SetFocus() ;
|
SetFocus() ;
|
||||||
|
|
||||||
#if TARGET_CARBON
|
#if TARGET_CARBON
|
||||||
BeginAppModalStateForWindow( (WindowRef) MacGetWindowRef()) ;
|
WindowRef windowRef = (WindowRef) MacGetWindowRef();
|
||||||
|
WindowGroupRef formerGroup = GetWindowGroup(windowRef) ;
|
||||||
|
SetWindowGroup( windowRef, GetWindowGroupOfClass( kMovableModalWindowClass ));
|
||||||
|
BeginAppModalStateForWindow(windowRef) ;
|
||||||
#else
|
#else
|
||||||
// TODO : test whether parent gets disabled
|
// TODO : test whether parent gets disabled
|
||||||
bool formerModal = s_macIsInModalLoop ;
|
bool formerModal = s_macIsInModalLoop ;
|
||||||
@@ -160,7 +163,8 @@ void wxDialog::DoShowModal()
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if TARGET_CARBON
|
#if TARGET_CARBON
|
||||||
EndAppModalStateForWindow( (WindowRef) MacGetWindowRef() ) ;
|
EndAppModalStateForWindow(windowRef) ;
|
||||||
|
SetWindowGroup( windowRef, formerGroup );
|
||||||
#else
|
#else
|
||||||
// TODO probably reenable the parent window if any
|
// TODO probably reenable the parent window if any
|
||||||
s_macIsInModalLoop = formerModal ;
|
s_macIsInModalLoop = formerModal ;
|
||||||
|
Reference in New Issue
Block a user