]> git.saurik.com Git - wxWidgets.git/blob - src/qt/slider.cpp
A few weeks of Unicode fixes (my old win95 laptop compiles sloowly,
[wxWidgets.git] / src / qt / slider.cpp
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: slider.cpp
3 // Purpose: wxSlider
4 // Author: AUTHOR
5 // Modified by:
6 // Created: ??/??/98
7 // RCS-ID: $Id$
8 // Copyright: (c) AUTHOR
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #ifdef __GNUG__
13 #pragma implementation "slider.h"
14 #endif
15
16 #include "wx/msw/slider.h"
17
18 #if !USE_SHARED_LIBRARY
19 IMPLEMENT_DYNAMIC_CLASS(wxSlider, wxControl)
20 #endif
21
22 // Slider
23 wxSlider::wxSlider()
24 {
25 m_pageSize = 1;
26 m_lineSize = 1;
27 m_rangeMax = 0;
28 m_rangeMin = 0;
29 m_tickFreq = 0;
30 }
31
32 bool wxSlider::Create(wxWindow *parent, wxWindowID id,
33 int value, int minValue, int maxValue,
34 const wxPoint& pos,
35 const wxSize& size, long style,
36 const wxValidator& validator,
37 const wxString& name)
38 {
39 SetName(name);
40 SetValidator(validator);
41
42 if (parent) parent->AddChild(this);
43
44 m_lineSize = 1;
45 m_windowStyle = style;
46 m_tickFreq = 0;
47
48 if ( id == -1 )
49 m_windowId = (int)NewControlId();
50 else
51 m_windowId = id;
52
53 m_rangeMax = maxValue;
54 m_rangeMin = minValue;
55
56 m_pageSize = (int)((maxValue-minValue)/10);
57
58 // TODO create slider
59
60 return FALSE;
61 }
62
63 wxSlider::~wxSlider()
64 {
65 }
66
67 int wxSlider::GetValue() const
68 {
69 // TODO
70 return 0;
71 }
72
73 void wxSlider::SetValue(int value)
74 {
75 // TODO
76 }
77
78 void wxSlider::GetSize(int *width, int *height) const
79 {
80 // TODO
81 }
82
83 void wxSlider::GetPosition(int *x, int *y) const
84 {
85 // TODO
86 }
87
88 void wxSlider::SetSize(int x, int y, int width, int height, int sizeFlags)
89 {
90 // TODO
91 }
92
93 void wxSlider::SetRange(int minValue, int maxValue)
94 {
95 m_rangeMin = minValue;
96 m_rangeMax = maxValue;
97
98 // TODO
99 }
100
101 // For trackbars only
102 void wxSlider::SetTickFreq(int n, int pos)
103 {
104 // TODO
105 m_tickFreq = n;
106 }
107
108 void wxSlider::SetPageSize(int pageSize)
109 {
110 // TODO
111 m_pageSize = pageSize;
112 }
113
114 int wxSlider::GetPageSize() const
115 {
116 return m_pageSize;
117 }
118
119 void wxSlider::ClearSel()
120 {
121 // TODO
122 }
123
124 void wxSlider::ClearTicks()
125 {
126 // TODO
127 }
128
129 void wxSlider::SetLineSize(int lineSize)
130 {
131 m_lineSize = lineSize;
132 // TODO
133 }
134
135 int wxSlider::GetLineSize() const
136 {
137 // TODO
138 return 0;
139 }
140
141 int wxSlider::GetSelEnd() const
142 {
143 // TODO
144 return 0;
145 }
146
147 int wxSlider::GetSelStart() const
148 {
149 // TODO
150 return 0;
151 }
152
153 void wxSlider::SetSelection(int minPos, int maxPos)
154 {
155 // TODO
156 }
157
158 void wxSlider::SetThumbLength(int len)
159 {
160 // TODO
161 }
162
163 int wxSlider::GetThumbLength() const
164 {
165 // TODO
166 return 0;
167 }
168
169 void wxSlider::SetTick(int tickPos)
170 {
171 // TODO
172 }
173
174 void wxSlider::Command (wxCommandEvent & event)
175 {
176 SetValue (event.GetInt());
177 ProcessCommand (event);
178 }
179
180 bool wxSlider::Show(bool show)
181 {
182 // TODO
183 return TRUE;
184 }
185