X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/d162a7ee7d6bab3d0c714b865806377aeb5d0d9e..6e76b35d73fb5a043fd39af266bd452a6e20a861:/src/msw/mdi.cpp diff --git a/src/msw/mdi.cpp b/src/msw/mdi.cpp index a11484a3ed..db396ec1a3 100644 --- a/src/msw/mdi.cpp +++ b/src/msw/mdi.cpp @@ -5,8 +5,8 @@ // Modified by: // Created: 04/01/98 // RCS-ID: $Id$ -// Copyright: (c) Julian Smart and Markus Holzem -// Licence: wxWindows license +// Copyright: (c) Julian Smart +// Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// // =========================================================================== @@ -17,7 +17,7 @@ // headers // --------------------------------------------------------------------------- -#ifdef __GNUG__ +#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) #pragma implementation "mdi.h" #endif @@ -28,6 +28,8 @@ #pragma hdrstop #endif +#if wxUSE_MDI_ARCHITECTURE && !defined(__WXUNIVERSAL__) + #ifndef WX_PRECOMP #include "wx/setup.h" #include "wx/frame.h" @@ -43,8 +45,6 @@ #include "wx/log.h" #endif -#if wxUSE_MDI_ARCHITECTURE && !defined(__WXUNIVERSAL__) - #include "wx/mdi.h" #include "wx/msw/private.h" @@ -68,7 +68,6 @@ extern wxMenu *wxCurrentPopupMenu; extern const wxChar *wxMDIFrameClassName; // from app.cpp extern const wxChar *wxMDIChildFrameClassName; extern const wxChar *wxMDIChildFrameClassNameNoRedraw; - extern void wxAssociateWinWithHandle(HWND hWnd, wxWindow *win); extern void wxRemoveHandleAssociation(wxWindow *win); @@ -212,6 +211,8 @@ bool wxMDIParentFrame::Create(wxWindow *parent, WXDWORD exflags; WXDWORD msflags = MSWGetCreateWindowFlags(&exflags); + msflags &= ~WS_VSCROLL; + msflags &= ~WS_HSCROLL; if ( !wxWindow::MSWCreate(wxMDIFrameClassName, title, @@ -341,8 +342,8 @@ void wxMDIParentFrame::OnSysColourChanged(wxSysColourChangedEvent& event) WXHICON wxMDIParentFrame::GetDefaultIcon() const { - return (WXHICON)(wxSTD_MDIPARENTFRAME_ICON ? wxSTD_MDIPARENTFRAME_ICON - : wxDEFAULT_MDIPARENTFRAME_ICON); + // we don't have any standard icons (any more) + return (WXHICON)0; } // --------------------------------------------------------------------------- @@ -407,13 +408,13 @@ long wxMDIParentFrame::MSWWindowProc(WXUINT message, (void)HandleCommand(id, cmd, hwnd); // even if the frame didn't process it, there is no need to try it - // once again (i.e. call wxFrame::HandleCommand()) - we just dud it, + // once again (i.e. call wxFrame::HandleCommand()) - we just did it, // so pretend we processed the message anyhow processed = true; } // always pass this message DefFrameProc(), otherwise MDI menu - // commands (and sys commands - more surprizingly!) won't work + // commands (and sys commands - more surprisingly!) won't work MSWDefWindowProc(message, wParam, lParam); break; @@ -557,7 +558,7 @@ bool wxMDIParentFrame::HandleCommand(WXWORD id, WXWORD cmd, WXHWND hwnd) if ( IsMdiCommandId(id) ) { - wxWindowList::Node *node = GetChildren().GetFirst(); + wxWindowList::compatibility_iterator node = GetChildren().GetFirst(); while ( node ) { wxWindow *child = node->GetData(); @@ -670,9 +671,9 @@ bool wxMDIChildFrame::Create(wxMDIParentFrame *parent, MDICREATESTRUCT mcs; - mcs.szClass = style & wxNO_FULL_REPAINT_ON_RESIZE - ? wxMDIChildFrameClassNameNoRedraw - : wxMDIChildFrameClassName; + mcs.szClass = style & wxFULL_REPAINT_ON_RESIZE + ? wxMDIChildFrameClassName + : wxMDIChildFrameClassNameNoRedraw; mcs.szTitle = title; mcs.hOwner = wxGetInstance(); if (x > -1) @@ -695,7 +696,7 @@ bool wxMDIChildFrame::Create(wxMDIParentFrame *parent, else mcs.cy = CW_USEDEFAULT; - DWORD msflags = WS_OVERLAPPED | WS_CLIPCHILDREN | WS_THICKFRAME | WS_VISIBLE ; + DWORD msflags = WS_OVERLAPPED | WS_CLIPCHILDREN | WS_VISIBLE ; if (style & wxMINIMIZE_BOX) msflags |= WS_MINIMIZEBOX; if (style & wxMAXIMIZE_BOX) @@ -810,8 +811,8 @@ void wxMDIChildFrame::InternalSetMenuBar() WXHICON wxMDIChildFrame::GetDefaultIcon() const { - return (WXHICON)(wxSTD_MDICHILDFRAME_ICON ? wxSTD_MDICHILDFRAME_ICON - : wxDEFAULT_MDICHILDFRAME_ICON); + // we don't have any standard icons (any more) + return (WXHICON)0; } // --------------------------------------------------------------------------- @@ -1063,7 +1064,7 @@ bool wxMDIChildFrame::HandleGetMinMaxInfo(void *mmInfo) processed = true; } - return true; + return processed; } // --------------------------------------------------------------------------- @@ -1245,7 +1246,7 @@ void wxMDIClientWindow::DoSetSize(int x, int y, int width, int height, int sizeF { if (GetParent()) { - wxWindowList::Node *node = GetParent()->GetChildren().GetFirst(); + wxWindowList::compatibility_iterator node = GetParent()->GetChildren().GetFirst(); while (node) { wxWindow *child = node->GetData();