From 6819fb9bef7a71a74ddb41fed7a9e9945b7cb254 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Thu, 12 Feb 2004 18:19:12 +0000 Subject: [PATCH] don't override GetSize(), this doesn't work (bug 732758) git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@25773 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- include/wx/msw/slider95.h | 2 -- src/msw/slider95.cpp | 11 ++++------- 2 files changed, 4 insertions(+), 9 deletions(-) diff --git a/include/wx/msw/slider95.h b/include/wx/msw/slider95.h index d1efb04d8c..928ec45a03 100644 --- a/include/wx/msw/slider95.h +++ b/include/wx/msw/slider95.h @@ -46,8 +46,6 @@ public: virtual int GetValue() const; virtual void SetValue(int); - void GetSize(int *w, int *h) const; - void GetPosition(int *x, int *y) const; bool Show(bool show = TRUE); diff --git a/src/msw/slider95.cpp b/src/msw/slider95.cpp index 8485eb368f..cca538bbff 100644 --- a/src/msw/slider95.cpp +++ b/src/msw/slider95.cpp @@ -394,11 +394,6 @@ void wxSlider95::SetValue(int value) } void wxSlider95::DoGetSize(int *width, int *height) const -{ - GetSize(width, height); -} - -void wxSlider95::GetSize(int *width, int *height) const { RECT rect; rect.left = -1; rect.right = -1; rect.top = -1; rect.bottom = -1; @@ -414,8 +409,10 @@ void wxSlider95::GetSize(int *width, int *height) const if (m_staticValue) wxFindMaxSize(m_staticValue, &rect); - *width = rect.right - rect.left; - *height = rect.bottom - rect.top; + if ( width ) + *width = rect.right - rect.left; + if ( height ) + *height = rect.bottom - rect.top; } void wxSlider95::GetPosition(int *x, int *y) const -- 2.45.2