// ----------------------------------------------------------------------------
// For compilers that support precompilation, includes "wx/wx.h".
-#include <wx/wxprec.h>
+#include "wx/wxprec.h"
#ifdef __BORLANDC__
#pragma hdrstop
#endif
#ifndef WX_PRECOMP
- #include <wx/app.h>
- #include <wx/frame.h>
- #include <wx/menu.h>
- #include <wx/msgdlg.h>
- #include <wx/log.h>
- #include <wx/textctrl.h>
+ #include "wx/app.h"
+ #include "wx/frame.h"
+ #include "wx/menu.h"
+ #include "wx/msgdlg.h"
+ #include "wx/log.h"
+ #include "wx/textctrl.h"
#endif
#if !wxUSE_MENUS
: wxFrame((wxFrame *)NULL, -1, "wxWindows menu sample",
wxDefaultPosition, wxSize(300, 200))
{
+ m_textctrl = NULL;
m_menu = NULL;
m_countDummy = 0;
m_logOld = NULL;
void MyFrame::OnSize(wxSizeEvent& event)
{
+ if ( !m_textctrl )
+ return;
+
// leave a band below for popup menu testing
wxSize size = GetClientSize();
m_textctrl->SetSize(0, 0, size.x, (3*size.y)/4);