// For compilers that support precompilation, includes "wx.h".
#include "wx/wxprec.h"
-#ifdef __VMS
-#define XtDisplay XTDISPLAY
-#define XtWindow XTWINDOW
-#endif
-
#include "wx/mdi.h"
#ifndef WX_PRECOMP
#include "wx/menu.h"
#include "wx/icon.h"
+ #include "wx/settings.h"
#endif
-#include "wx/settings.h"
-
#ifdef __VMS__
#pragma message disable nosimpint
#endif
bool res = false;
if (m_activeChild && event.IsKindOf(CLASSINFO(wxCommandEvent)))
{
- res = m_activeChild->GetEventHandler()->ProcessEvent(event);
+ res = m_activeChild->HandleWindowEvent(event);
}
if (!res)
SetName(name);
SetWindowStyleFlag(style);
- m_backgroundColour = wxSystemSettings::GetColour(wxSYS_COLOUR_APPWORKSPACE);
- m_foregroundColour = *wxBLACK;
- m_font = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT);
-
if ( id > -1 )
m_windowId = id;
else
wxMDIClientWindow* clientWindow = parent->GetClientWindow();
- wxASSERT_MSG( (clientWindow != (wxWindow*) NULL), "Missing MDI client window.");
+ wxCHECK_MSG( clientWindow, false, "Missing MDI client window." );
- if (clientWindow) clientWindow->AddChild(this);
+ clientWindow->AddChild(this);
SetMDIParentFrame(parent);
+ PreCreation();
int width = size.x;
int height = size.y;
{
wxActivateEvent event(wxEVT_ACTIVATE, false, oldActiveChild->GetId());
event.SetEventObject( oldActiveChild );
- oldActiveChild->GetEventHandler()->ProcessEvent(event);
+ oldActiveChild->HandleWindowEvent(event);
}
// This is the currently active child
XtAddEventHandler((Widget) m_mainWidget, ExposureMask,False,
wxUniversalRepaintProc, (XtPointer) this);
+ PostCreation();
AttachWidget (parent, m_mainWidget, (WXWidget) NULL, pos.x, pos.y, size.x, size.y);
- ChangeBackgroundColour();
-
XtManageChild((Widget) m_mainWidget);
SetTitle(title);
{
wxActivateEvent event(wxEVT_ACTIVATE, false, oldActiveChild->GetId());
event.SetEventObject( oldActiveChild );
- oldActiveChild->GetEventHandler()->ProcessEvent(event);
+ oldActiveChild->HandleWindowEvent(event);
}
wxActivateEvent event(wxEVT_ACTIVATE, true, this->GetId());
event.SetEventObject( this );
- this->GetEventHandler()->ProcessEvent(event);
+ this->HandleWindowEvent(event);
}
void wxMDIChildFrame::OnLower()
{
wxActivateEvent event(wxEVT_ACTIVATE, false, oldActiveChild->GetId());
event.SetEventObject( oldActiveChild );
- oldActiveChild->GetEventHandler()->ProcessEvent(event);
+ oldActiveChild->HandleWindowEvent(event);
}
// TODO: unfortunately we don't now know which is the top-most child,
// so make the active child NULL.
{
SetWindowStyleFlag(style);
- // m_windowParent = parent;
- // m_backgroundColour = wxSystemSettings::GetColour(wxSYS_COLOUR_APPWORKSPACE);
-
bool success = wxNotebook::Create(parent, wxID_NOTEBOOK_CLIENT_AREA, wxPoint(0, 0), wxSize(100, 100), 0);
if (success)
{
- wxFont font(10, wxSWISS, wxNORMAL, wxNORMAL);
- SetFont(font);
return true;
}
else
{
wxActivateEvent event(wxEVT_ACTIVATE, false, oldChild->GetId());
event.SetEventObject( oldChild );
- oldChild->GetEventHandler()->ProcessEvent(event);
+ oldChild->HandleWindowEvent(event);
}
}
if (event.GetSelection() != -1)
{
wxActivateEvent event(wxEVT_ACTIVATE, true, activeChild->GetId());
event.SetEventObject( activeChild );
- activeChild->GetEventHandler()->ProcessEvent(event);
+ activeChild->HandleWindowEvent(event);
if (activeChild->GetMDIParentFrame())
{