wx..._EX_METAL styles support

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@36138 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Stefan Csomor
2005-11-09 09:45:58 +00:00
parent 5c60e84569
commit 8ec0a8fa72
2 changed files with 29 additions and 0 deletions

View File

@@ -1208,6 +1208,16 @@ void wxTopLevelWindowMac::MacCreateRealWindow( const wxString& title,
// the root control level handleer
MacInstallEventHandler( (WXWidget) m_peer->GetControlRef() ) ;
#if TARGET_API_MAC_OSX
if ( m_macUsesCompositing && m_macWindow != NULL )
{
if ( GetExtraStyle() & wxFRAME_EX_METAL )
MacSetMetalAppearance( true ) ;
}
#endif
// the frame window event handler
InstallStandardEventHandler( GetWindowEventTarget(MAC_WXHWND(m_macWindow)) ) ;
MacInstallTopLevelWindowEventHandler() ;
@@ -1385,6 +1395,23 @@ bool wxTopLevelWindowMac::IsFullScreen() const
return m_macFullScreenData != NULL ;
}
void wxTopLevelWindowMac::SetExtraStyle(long exStyle)
{
if ( GetExtraStyle() == exStyle )
return ;
wxTopLevelWindowBase::SetExtraStyle( exStyle ) ;
#if TARGET_API_MAC_OSX
if ( m_macUsesCompositing && m_macWindow != NULL )
{
bool metal = GetExtraStyle() & wxFRAME_EX_METAL ;
if ( MacGetMetalAppearance() != metal )
MacSetMetalAppearance( metal ) ;
}
#endif
}
// we are still using coordinates of the content view, todo switch to structure bounds
void wxTopLevelWindowMac::MacGetContentAreaInset( int &left , int &top , int &right , int &bottom )