From 1b7735e10f1f9dc889c9817a8066ef34e399328f Mon Sep 17 00:00:00 2001 From: David Webster Date: Sun, 10 Feb 2002 04:33:20 +0000 Subject: [PATCH] Removing OS/2 specific positioning methods, no longer needed git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@14098 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/os2/toplevel.h | 5 ----- include/wx/os2/window.h | 3 ++- include/wx/toplevel.h | 9 --------- include/wx/window.h | 4 ---- src/common/toplvcmn.cpp | 10 ---------- src/common/wincmn.cpp | 3 --- 6 files changed, 2 insertions(+), 32 deletions(-) diff --git a/include/wx/os2/toplevel.h b/include/wx/os2/toplevel.h index 2557c3981f..a54b9d9602 100644 --- a/include/wx/os2/toplevel.h +++ b/include/wx/os2/toplevel.h @@ -83,11 +83,6 @@ public: // Implementation from now on // -------------------------- // - virtual void AlterChildPos(void); // OS/2 child control positioning - virtual void UpdateInternalSize( wxWindow* pChild - ,int nWidth - ,int nHeight - ); PSWP GetSwpClient(void) { return &m_vSwpClient; } protected: // diff --git a/include/wx/os2/window.h b/include/wx/os2/window.h index aa2553e8fa..66bdc201c6 100644 --- a/include/wx/os2/window.h +++ b/include/wx/os2/window.h @@ -453,6 +453,7 @@ public: ); void MoveChildren(int nDiff); + PSWP GetSwp(void) {return &m_vWinSwp;} protected: // PM can't create some MSW styles natively but can perform these after @@ -541,7 +542,6 @@ protected: #endif // wxUSE_TOOLTIPS int GetOS2ParentHeight(wxWindowOS2* pParent); - virtual void OS2Layout(int nWidth, int nHeight); private: // common part of all ctors @@ -572,6 +572,7 @@ private: private: HWND m_hWndScrollBarHorz; HWND m_hWndScrollBarVert; + SWP m_vWinSwp; // Virtual function hiding supression inline virtual bool Reparent(wxWindowBase* pNewParent) diff --git a/include/wx/toplevel.h b/include/wx/toplevel.h index 51caf5929d..f5a64871b7 100644 --- a/include/wx/toplevel.h +++ b/include/wx/toplevel.h @@ -122,15 +122,6 @@ public: // so should be there for all platforms void OnActivate(wxActivateEvent &WXUNUSED(event)) { } - // Override in derived, platfrom specific, class if your OS coordinate - // system uses anything other than the top left as 0,0. The second - // method updates any internal sizing parameters such as OS/2's SWP struct - inline virtual void AlterChildPos(void) { } - inline virtual void UpdateInternalSize( wxWindow* WXUNUSED(pChild) - ,int WXUNUSED(nWidth) - ,int WXUNUSED(nHeight) - ) { } - protected: // the frame client to screen translation should take account of the // toolbar which may shift the origin of the client area diff --git a/include/wx/window.h b/include/wx/window.h index 6d6edb28f3..1035f06356 100644 --- a/include/wx/window.h +++ b/include/wx/window.h @@ -962,10 +962,6 @@ protected: // a toolbar that it manages itself). virtual void AdjustForParentClientOrigin(int& x, int& y, int sizeFlags); -#ifdef __WXPM__ - // extra OS/2 layout processing - virtual void OS2Layout(int width, int height) { }; -#endif private: diff --git a/src/common/toplvcmn.cpp b/src/common/toplvcmn.cpp index a67959b9f0..6c9f3d89f9 100644 --- a/src/common/toplvcmn.cpp +++ b/src/common/toplvcmn.cpp @@ -137,9 +137,6 @@ void wxTopLevelWindowBase::OnSize(wxSizeEvent& WXUNUSED(event)) { if ( child ) { -#ifdef __WXPM__ - AlterChildPos(); -#endif return; // it's our second subwindow - nothing to do } @@ -162,14 +159,7 @@ void wxTopLevelWindowBase::OnSize(wxSizeEvent& WXUNUSED(event)) static const int ofs = 0; #endif -#ifdef __WXPM__ - // OS/2 PM has to do a LOT of stuff to get things - // positioned right, especially if the child is a - // scrolled window. - UpdateInternalSize(child, clientW, clientH); -#else child->SetSize(ofs, ofs, clientW - 2*ofs, clientH - 2*ofs); -#endif } } } diff --git a/src/common/wincmn.cpp b/src/common/wincmn.cpp index b76a5c348c..26cdbc173e 100644 --- a/src/common/wincmn.cpp +++ b/src/common/wincmn.cpp @@ -1194,9 +1194,6 @@ bool wxWindowBase::Layout() GetClientSize(&w, &h); GetSizer()->SetDimension( 0, 0, w, h ); -#if defined __WXPM__ - OS2Layout(w, h); -#endif } else { -- 2.45.2