X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f5419957e5794f2d10f4e125f77b2c2e2cd222d6..a3ef5bf5045991260005634272633717c0a26174:/src/msw/frame.cpp diff --git a/src/msw/frame.cpp b/src/msw/frame.cpp index 8616d1a2ae..6382aba2f9 100644 --- a/src/msw/frame.cpp +++ b/src/msw/frame.cpp @@ -45,7 +45,7 @@ #endif extern wxList wxModelessWindows; -extern wxList wxPendingDelete; +extern wxList WXDLLEXPORT wxPendingDelete; extern char wxFrameClassName[]; extern wxMenu *wxCurrentPopupMenu; @@ -331,6 +331,12 @@ bool wxFrame::IsIconized(void) const return m_iconized; } +// Is it maximized? +bool wxFrame::IsMaximized(void) const +{ + return (::IsZoomed((HWND) GetHWND()) != 0) ; +} + void wxFrame::SetTitle(const wxString& title) { SetWindowText((HWND) GetHWND(), (const char *)title); @@ -370,7 +376,7 @@ wxStatusBar *wxFrame::OnCreateStatusBar(int number, long style, wxWindowID id, // Set the height according to the font and the border size wxClientDC dc(statusBar); - dc.SetFont(* statusBar->GetFont()); + dc.SetFont(statusBar->GetFont()); long x, y; dc.GetTextExtent("X", &x, &y); @@ -508,7 +514,7 @@ bool wxFrame::LoadAccelerators(const wxString& table) void wxFrame::Fit(void) { // Work out max. size - wxNode *node = GetChildren()->First(); + wxNode *node = GetChildren().First(); int max_width = 0; int max_height = 0; while (node) @@ -606,6 +612,11 @@ void wxFrame::MSWCreate(int id, wxWindow *parent, const char *wclass, wxWindow * WXDWORD extendedStyle = MakeExtendedStyle(style); +#if !defined(__WIN16__) && !defined(__SC__) + if (style & wxFRAME_TOOL_WINDOW) + extendedStyle |= WS_EX_TOOLWINDOW; +#endif + if (style & wxSTAY_ON_TOP) extendedStyle |= WS_EX_TOPMOST; @@ -801,7 +812,7 @@ void wxFrame::OnSize(wxSizeEvent& event) // do we have _exactly_ one child? wxWindow *child = NULL; - for ( wxNode *node = GetChildren()->First(); node; node = node->Next() ) + for ( wxNode *node = GetChildren().First(); node; node = node->Next() ) { wxWindow *win = (wxWindow *)node->Data(); if ( !win->IsKindOf(CLASSINFO(wxFrame)) && @@ -831,7 +842,7 @@ void wxFrame::OnSize(wxSizeEvent& event) // subwindow found. void wxFrame::OnActivate(wxActivateEvent& event) { - for(wxNode *node = GetChildren()->First(); node; node = node->Next()) + for(wxNode *node = GetChildren().First(); node; node = node->Next()) { // Find a child that's a subwindow, but not a dialog box. wxWindow *child = (wxWindow *)node->Data(); @@ -1037,7 +1048,7 @@ void wxFrame::PositionToolBar(void) // propagate our state change to all child frames void wxFrame::IconizeChildFrames(bool bIconize) { - for ( wxNode *node = GetChildren()->First(); node; node = node->Next() ) { + for ( wxNode *node = GetChildren().First(); node; node = node->Next() ) { wxWindow *win = (wxWindow *)node->Data(); if ( win->IsKindOf(CLASSINFO(wxFrame)) ) { ((wxFrame *)win)->Iconize(bIconize);