show tooltips for the text control part of the spin control as well (bug 735044)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32442 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -96,6 +96,9 @@ protected:
|
|||||||
virtual void DoMoveWindow(int x, int y, int width, int height);
|
virtual void DoMoveWindow(int x, int y, int width, int height);
|
||||||
virtual wxSize DoGetBestSize() const;
|
virtual wxSize DoGetBestSize() const;
|
||||||
virtual void DoGetSize(int *width, int *height) const;
|
virtual void DoGetSize(int *width, int *height) const;
|
||||||
|
#if wxUSE_TOOLTIPS
|
||||||
|
virtual void DoSetToolTip( wxToolTip *tip );
|
||||||
|
#endif // wxUSE_TOOLTIPS
|
||||||
|
|
||||||
// the handler for wxSpinButton events
|
// the handler for wxSpinButton events
|
||||||
void OnSpinChange(wxSpinEvent& event);
|
void OnSpinChange(wxSpinEvent& event);
|
||||||
|
@@ -5,7 +5,7 @@
|
|||||||
// Modified by:
|
// Modified by:
|
||||||
// Created: 22.07.99
|
// Created: 22.07.99
|
||||||
// RCS-ID: $Id$
|
// RCS-ID: $Id$
|
||||||
// Copyright: (c) Vadim Zeitlin
|
// Copyright: (c) 1999-2005 Vadim Zeitlin
|
||||||
// Licence: wxWindows licence
|
// Licence: wxWindows licence
|
||||||
/////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
@@ -35,14 +35,13 @@
|
|||||||
|
|
||||||
#if wxUSE_SPINCTRL
|
#if wxUSE_SPINCTRL
|
||||||
|
|
||||||
#if defined(__WIN95__)
|
|
||||||
|
|
||||||
#include "wx/spinctrl.h"
|
#include "wx/spinctrl.h"
|
||||||
#include "wx/msw/private.h"
|
#include "wx/msw/private.h"
|
||||||
|
#include "wx/msw/wrapcctl.h"
|
||||||
|
|
||||||
#if defined(__WIN95__) && !(defined(__GNUWIN32_OLD__) && !defined(__CYGWIN10__))
|
#if wxUSE_TOOLTIPS
|
||||||
#include <commctrl.h>
|
#include "wx/tooltip.h"
|
||||||
#endif
|
#endif // wxUSE_TOOLTIPS
|
||||||
|
|
||||||
#include <limits.h> // for INT_MIN
|
#include <limits.h> // for INT_MIN
|
||||||
|
|
||||||
@@ -502,6 +501,18 @@ void wxSpinCtrl::SetFocus()
|
|||||||
::SetFocus(GetBuddyHwnd());
|
::SetFocus(GetBuddyHwnd());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if wxUSE_TOOLTIPS
|
||||||
|
|
||||||
|
void wxSpinCtrl::DoSetToolTip(wxToolTip *tip)
|
||||||
|
{
|
||||||
|
wxSpinButton::DoSetToolTip(tip);
|
||||||
|
|
||||||
|
if ( tip )
|
||||||
|
tip->Add(m_hwndBuddy);
|
||||||
|
}
|
||||||
|
|
||||||
|
#endif // wxUSE_TOOLTIPS
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
// event processing
|
// event processing
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
@@ -593,8 +604,5 @@ void wxSpinCtrl::DoGetPosition(int *x, int *y) const
|
|||||||
wxConstCast(this, wxSpinCtrl)->m_hWnd = hWnd;
|
wxConstCast(this, wxSpinCtrl)->m_hWnd = hWnd;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // __WIN95__
|
#endif // wxUSE_SPINCTRL
|
||||||
|
|
||||||
#endif
|
|
||||||
// wxUSE_SPINCTRL
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user