]> git.saurik.com Git - wxWidgets.git/blob - include/wx/cocoa/spinbutt.h
Fix wxPropertyGrid::GetPropertyRect when the last item is collapsed.
[wxWidgets.git] / include / wx / cocoa / spinbutt.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/cocoa/spinbutt.h
3 // Purpose: wxSpinButton class
4 // Author: David Elliott
5 // Modified by:
6 // Created: 2003/07/14
7 // Copyright: (c) 2003 David Elliott
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
10
11 #ifndef __WX_COCOA_SPINBUTT_H__
12 #define __WX_COCOA_SPINBUTT_H__
13
14 // #include "wx/cocoa/NSStepper.h"
15
16 // ========================================================================
17 // wxSpinButton
18 // ========================================================================
19 class WXDLLIMPEXP_CORE wxSpinButton: public wxSpinButtonBase// , protected wxCocoaNSStepper
20 {
21 DECLARE_DYNAMIC_CLASS(wxSpinButton)
22 DECLARE_EVENT_TABLE()
23 // WX_DECLARE_COCOA_OWNER(NSStepper,NSControl,NSView)
24 // ------------------------------------------------------------------------
25 // initialization
26 // ------------------------------------------------------------------------
27 public:
28 wxSpinButton() { }
29 wxSpinButton(wxWindow *parent, wxWindowID winid = wxID_ANY,
30 const wxPoint& pos = wxDefaultPosition,
31 const wxSize& size = wxDefaultSize,
32 long style = wxSP_VERTICAL | wxSP_ARROW_KEYS,
33 const wxString& name = wxSPIN_BUTTON_NAME)
34 {
35 Create(parent, winid, pos, size, style, name);
36 }
37
38 bool Create(wxWindow *parent, wxWindowID winid = wxID_ANY,
39 const wxPoint& pos = wxDefaultPosition,
40 const wxSize& size = wxDefaultSize,
41 long style = wxSP_HORIZONTAL,
42 const wxString& name = wxSPIN_BUTTON_NAME);
43 virtual ~wxSpinButton();
44
45 // ------------------------------------------------------------------------
46 // Cocoa callbacks
47 // ------------------------------------------------------------------------
48 protected:
49 virtual void CocoaTarget_action();
50 // ------------------------------------------------------------------------
51 // Implementation
52 // ------------------------------------------------------------------------
53 public:
54 // Pure Virtuals
55 virtual int GetValue() const;
56 virtual void SetValue(int value);
57
58 // retrieve/change the range
59 virtual void SetRange(int minValue, int maxValue);
60 };
61
62 #endif
63 // __WX_COCOA_SPINBUTT_H__