]> git.saurik.com Git - wxWidgets.git/blame - include/wx/gtk/spinbutt.h
Removed unnecessary code from utilsunx.cpp
[wxWidgets.git] / include / wx / gtk / spinbutt.h
CommitLineData
8e189077
RR
1/////////////////////////////////////////////////////////////////////////////
2// Name: spinbutt.h
3// Purpose: wxSpinButton class
4// Author: Robert Roebling
5// Modified by:
6// RCS-ID: $Id$
7// Copyright: (c) Robert Roebling
31528cd3 8// Licence: wxWindows licence
8e189077
RR
9/////////////////////////////////////////////////////////////////////////////
10
738f9e5a 11#ifndef __GTKSPINBUTTH__
8e189077
RR
12#define __GTKSPINBUTTH__
13
14#ifdef __GNUG__
15#pragma interface
16#endif
17
a075e27b
RR
18#include "wx/defs.h"
19
20#if wxUSE_SPINBTN
21
22#include "wx/control.h"
23
8e189077
RR
24//-----------------------------------------------------------------------------
25// wxSpinButton
26//-----------------------------------------------------------------------------
27
31528cd3 28class wxSpinButton : public wxSpinButtonBase
8e189077 29{
8e189077 30public:
31528cd3
VZ
31 wxSpinButton() { }
32 wxSpinButton( wxWindow *parent, wxWindowID id = -1,
33 const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize,
34 long style = wxSP_VERTICAL, const wxString& name = "wxSpinButton")
35 {
36 Create(parent, id, pos, size, style, name);
37 }
31528cd3
VZ
38
39 bool Create( wxWindow *parent, wxWindowID id = -1,
40 const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize,
41 long style = wxSP_VERTICAL, const wxString& name = "wxSpinButton" );
42
43 virtual int GetValue() const;
44 virtual void SetValue( int value );
45 virtual void SetRange( int minVal, int maxVal );
46 virtual int GetMin() const;
47 virtual int GetMax() const;
48
49 // implementation
50 void OnSize( wxSizeEvent &event );
51
52 bool IsOwnGtkWindow( GdkWindow *window );
53 void ApplyWidgetStyle();
54
55 GtkAdjustment *m_adjust;
56 float m_oldPos;
57
9d9b7755
VZ
58protected:
59 virtual wxSize DoGetBestSize() const;
60
31528cd3
VZ
61private:
62 DECLARE_EVENT_TABLE()
738f9e5a 63 DECLARE_DYNAMIC_CLASS(wxSpinButton)
8e189077
RR
64};
65
a075e27b
RR
66#endif
67 // wxUSE_SPINBTN
68
8e189077
RR
69#endif
70 // __GTKSPINBUTTH__