#include "wx/sysopt.h"
#endif
-#include "ToolUtils.h"
+#include <ToolUtils.h>
#define wxMAC_DEBUG_REDRAW 0
{ kEventClassKeyboard, kEventRawKeyUp } ,
{ kEventClassKeyboard, kEventRawKeyModifiersChanged } ,
+ { kEventClassWindow , kEventWindowShown } ,
{ kEventClassWindow , kEventWindowUpdate } ,
{ kEventClassWindow , kEventWindowActivated } ,
{ kEventClassWindow , kEventWindowDeactivated } ,
toplevelWindow->MacActivate( EventTimeToTicks( GetEventTime( event ) ) , false) ;
result = noErr ;
break ;
+ case kEventWindowShown :
+ toplevelWindow->Refresh() ;
+ result = noErr ;
+ break ;
case kEventWindowClose :
toplevelWindow->Close() ;
result = noErr ;
if ( m_x < 20 )
m_x = 20 ;
- m_width = size.x;
- if (m_width == -1)
- m_width = 20;
- m_height = size.y;
- if (m_height == -1)
- m_height = 20;
+ m_width = WidthDefault(size.x);
+ m_height = HeightDefault(size.y);
::SetRect(&theBoundsRect, m_x, m_y , m_x + m_width, m_y + m_height);
wxCHECK_RET( err == noErr, wxT("Mac OS error when trying to create new window") );
wxAssociateWinWithMacWindow( m_macWindow , this ) ;
- UMASetWTitle( (WindowRef)m_macWindow , title ) ;
+ UMASetWTitle( (WindowRef)m_macWindow , title , m_font.GetEncoding() ) ;
if ( wxTopLevelWindowMac::s_macWindowCompositing )
{
::GetRootControl( (WindowRef)m_macWindow, (ControlHandle*)&m_macRootControl ) ;
void wxTopLevelWindowMac::SetTitle(const wxString& title)
{
wxWindow::SetTitle( title ) ;
- UMASetWTitle( (WindowRef)m_macWindow , title ) ;
+ UMASetWTitle( (WindowRef)m_macWindow , title , m_font.GetEncoding() ) ;
}
bool wxTopLevelWindowMac::Show(bool show)