#include "wx/statusbr.h"
#include "wx/toolbar.h"
#include "wx/menuitem.h"
+#include "wx/log.h"
#ifdef LoadAccelerators
#undef LoadAccelerators
m_frameMenuBar = NULL;
m_frameStatusBar = NULL;
- m_windowParent = NULL;
m_iconized = FALSE;
}
// we pass NULL as parent to MSWCreate because frames with parents behave
// very strangely under Win95 shell
- MSWCreate(m_windowId, NULL, wxFrameClassName, this, title,
+ // Alteration by JACS: keep normal Windows behaviour (float on top of parent)
+ // with this style.
+ if ((m_windowStyle & wxFRAME_FLOAT_ON_PARENT) == 0)
+ parent = NULL;
+
+ MSWCreate(m_windowId, parent, wxFrameClassName, this, title,
x, y, width, height, style);
wxModelessWindows.Append(this);
}
// Get size *available for subwindows* i.e. excluding menu bar, toolbar etc.
-void wxFrame::GetClientSize(int *x, int *y) const
+void wxFrame::DoGetClientSize(int *x, int *y) const
{
RECT rect;
::GetClientRect((HWND) GetHWND(), &rect);
GetEventHandler()->ProcessEvent(event);
}
-void wxFrame::GetSize(int *width, int *height) const
+void wxFrame::DoGetSize(int *width, int *height) const
{
RECT rect;
GetWindowRect((HWND) GetHWND(), &rect);
*height = rect.bottom - rect.top;
}
-void wxFrame::GetPosition(int *x, int *y) const
+void wxFrame::DoGetPosition(int *x, int *y) const
{
RECT rect;
GetWindowRect((HWND) GetHWND(), &rect);
{
bar->Check(id,!bar->Checked(id)) ;
}
- GetEventHandler()->ProcessEvent(commandEvent);
+
+/*
+ // Process events starting with the window with the focus, if any.
+ wxWindow* focusWin = wxFindFocusDescendant(this);
+
+ wxEvtHandler* evtHandler = focusWin ? focusWin->GetEventHandler() : GetEventHandler();
+*/
+
+ wxEvtHandler* evtHandler = GetEventHandler();
+ evtHandler->ProcessEvent(commandEvent);
}
// Checks if there is a toolbar, and returns the first free client position