wxMessageBox off the main thread lost result code.
[wxWidgets.git] / include / wx / motif / gauge.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/motif/gauge.h
3 // Purpose: wxGauge class
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 17/09/98
7 // Copyright: (c) Julian Smart
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
10
11 #ifndef _WX_GAUGE_H_
12 #define _WX_GAUGE_H_
13
14 // Group box
15 class WXDLLIMPEXP_CORE wxGauge : public wxGaugeBase
16 {
17 DECLARE_DYNAMIC_CLASS(wxGauge)
18
19 public:
20 inline wxGauge() { m_rangeMax = 0; m_gaugePos = 0; }
21
22 inline wxGauge(wxWindow *parent, wxWindowID id,
23 int range,
24 const wxPoint& pos = wxDefaultPosition,
25 const wxSize& size = wxDefaultSize,
26 long style = wxGA_HORIZONTAL,
27 const wxValidator& validator = wxDefaultValidator,
28 const wxString& name = wxGaugeNameStr)
29 {
30 Create(parent, id, range, pos, size, style, validator, name);
31 }
32
33 bool Create(wxWindow *parent, wxWindowID id,
34 int range,
35 const wxPoint& pos = wxDefaultPosition,
36 const wxSize& size = wxDefaultSize,
37 long style = wxGA_HORIZONTAL,
38 const wxValidator& validator = wxDefaultValidator,
39 const wxString& name = wxGaugeNameStr);
40
41 void SetShadowWidth(int w);
42 void SetRange(int r);
43 void SetValue(int pos);
44
45 int GetShadowWidth() const ;
46 int GetRange() const ;
47 int GetValue() const ;
48
49 virtual void Command(wxCommandEvent& WXUNUSED(event)) {} ;
50
51 private:
52 virtual wxSize DoGetBestSize() const;
53 virtual void DoMoveWindow(int x, int y, int width, int height);
54 };
55
56 #endif
57 // _WX_GAUGE_H_