]>
Commit | Line | Data |
---|---|---|
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 | ||
11 | #ifndef __GTKSPINPUTTH__ | |
12 | #define __GTKSPINBUTTH__ | |
13 | ||
14 | #ifdef __GNUG__ | |
15 | #pragma interface | |
16 | #endif | |
17 | ||
8e189077 RR |
18 | //----------------------------------------------------------------------------- |
19 | // wxSpinButton | |
20 | //----------------------------------------------------------------------------- | |
21 | ||
31528cd3 | 22 | class wxSpinButton : public wxSpinButtonBase |
8e189077 | 23 | { |
31528cd3 | 24 | DECLARE_DYNAMIC_CLASS(wxSpinButton) |
8e189077 RR |
25 | |
26 | public: | |
31528cd3 VZ |
27 | wxSpinButton() { } |
28 | wxSpinButton( wxWindow *parent, wxWindowID id = -1, | |
29 | const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, | |
30 | long style = wxSP_VERTICAL, const wxString& name = "wxSpinButton") | |
31 | { | |
32 | Create(parent, id, pos, size, style, name); | |
33 | } | |
34 | ~wxSpinButton(); | |
35 | ||
36 | bool Create( wxWindow *parent, wxWindowID id = -1, | |
37 | const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, | |
38 | long style = wxSP_VERTICAL, const wxString& name = "wxSpinButton" ); | |
39 | ||
40 | virtual int GetValue() const; | |
41 | virtual void SetValue( int value ); | |
42 | virtual void SetRange( int minVal, int maxVal ); | |
43 | virtual int GetMin() const; | |
44 | virtual int GetMax() const; | |
45 | ||
46 | // implementation | |
47 | void OnSize( wxSizeEvent &event ); | |
48 | ||
49 | bool IsOwnGtkWindow( GdkWindow *window ); | |
50 | void ApplyWidgetStyle(); | |
51 | ||
52 | GtkAdjustment *m_adjust; | |
53 | float m_oldPos; | |
54 | ||
55 | private: | |
56 | DECLARE_EVENT_TABLE() | |
8e189077 RR |
57 | }; |
58 | ||
8e189077 RR |
59 | #endif |
60 | // __GTKSPINBUTTH__ |