// Carbon Events
// ---------------------------------------------------------------------------
-extern long wxMacTranslateKey(unsigned char key, unsigned char code) ;
-
static const EventTypeSpec eventList[] =
{
// TODO: remove control related event like key and mouse (except for WindowLeave events)
wxPoint m_position ;
wxSize m_size ;
bool m_wasResizable ;
-}
-FullScreenData ;
+} FullScreenData ;
void wxTopLevelWindowMac::Init()
{
wxCHECK_RET( err == noErr, wxT("Mac OS error when trying to create new window") );
+ // setup a separate group for each window, so that overlays can be handled easily
+ verify_noerr( CreateWindowGroup( kWindowGroupAttrMoveTogether | kWindowGroupAttrLayerTogether | kWindowGroupAttrHideOnCollapse, &group ));
+ verify_noerr( SetWindowGroupParent( group, GetWindowGroup( (WindowRef) m_macWindow )));
+ verify_noerr( SetWindowGroup( (WindowRef) m_macWindow , group ));
+
// the create commands are only for content rect,
// so we have to set the size again as structure bounds
SetWindowBounds( (WindowRef) m_macWindow , kWindowStructureRgn , &theBoundsRect ) ;
EventRef currentEvent = (EventRef) wxTheApp->MacGetCurrentEvent() ;
UInt32 currentEventClass = 0 ;
- UInt32 currentEventKind = 0 ;
if ( currentEvent != NULL )
{
currentEventClass = ::GetEventClass( currentEvent ) ;
- currentEventKind = ::GetEventKind( currentEvent ) ;
+ ::GetEventKind( currentEvent ) ;
}
if ( currentEventClass != kEventClassMenu )
{
// when tracking a menu, strange redraw errors occur if we flush now, so leave..
EventRef theEvent;
- OSStatus status = noErr ;
- status = ReceiveNextEvent( 0 , NULL , kEventDurationNoWait , false , &theEvent ) ;
+ ReceiveNextEvent( 0 , NULL , kEventDurationNoWait , false , &theEvent ) ;
}
}
}