]> git.saurik.com Git - wxWidgets.git/blame - src/palmos/spinctrl.cpp
Remove now unnecessary comment.
[wxWidgets.git] / src / palmos / spinctrl.cpp
CommitLineData
ffecfa5a 1/////////////////////////////////////////////////////////////////////////////
e2731512 2// Name: src/palmos/spinctrl.cpp
ffecfa5a 3// Purpose: wxSpinCtrl class implementation for Palm OS
e2731512 4// Author: William Osborne - minimal working wxPalmOS port
ffecfa5a
JS
5// Modified by:
6// Created: 10/13/04
e2731512 7// RCS-ID: $Id$
ffecfa5a
JS
8// Copyright: (c) William Osborne
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12// ============================================================================
13// declarations
14// ============================================================================
15
ffecfa5a
JS
16// ----------------------------------------------------------------------------
17// headers
18// ----------------------------------------------------------------------------
19
20// for compilers that support precompilation, includes "wx.h".
21#include "wx/wxprec.h"
22
23#ifdef __BORLANDC__
24 #pragma hdrstop
25#endif
26
27#ifndef WX_PRECOMP
28 #include "wx/wx.h"
29#endif
30
31#if wxUSE_SPINCTRL
32
33#if defined(__WIN95__)
34
35#include "wx/spinctrl.h"
36#include "wx/palmos/private.h"
37
38// ----------------------------------------------------------------------------
39// macros
40// ----------------------------------------------------------------------------
41
ffecfa5a
JS
42BEGIN_EVENT_TABLE(wxSpinCtrl, wxSpinButton)
43 EVT_CHAR(wxSpinCtrl::OnChar)
44
45 EVT_SET_FOCUS(wxSpinCtrl::OnSetFocus)
46
47 EVT_SPIN(-1, wxSpinCtrl::OnSpinChange)
48END_EVENT_TABLE()
49
50#define GetBuddyHwnd() (HWND)(m_hwndBuddy)
51
52// ----------------------------------------------------------------------------
53// constants
54// ----------------------------------------------------------------------------
55
56// the margin between the up-down control and its buddy (can be arbitrary,
57// choose what you like - or may be decide during run-time depending on the
58// font size?)
59static const int MARGIN_BETWEEN = 1;
60
61// ============================================================================
62// implementation
63// ============================================================================
64
65wxArraySpins wxSpinCtrl::ms_allSpins;
66
67/* static */
68wxSpinCtrl *wxSpinCtrl::GetSpinForTextCtrl(WXHWND hwndBuddy)
69{
70 return NULL;
71}
72
73// process a WM_COMMAND generated by the buddy text control
74bool wxSpinCtrl::ProcessTextCommand(WXWORD cmd, WXWORD WXUNUSED(id))
75{
76 return false;
77}
78
79void wxSpinCtrl::OnChar(wxKeyEvent& event)
80{
81}
82
83void wxSpinCtrl::OnSetFocus(wxFocusEvent& event)
84{
85}
86
87// ----------------------------------------------------------------------------
88// construction
89// ----------------------------------------------------------------------------
90
91bool wxSpinCtrl::Create(wxWindow *parent,
92 wxWindowID id,
93 const wxString& value,
94 const wxPoint& pos,
95 const wxSize& size,
96 long style,
97 int min, int max, int initial,
98 const wxString& name)
99{
100 return false;
101}
102
103wxSpinCtrl::~wxSpinCtrl()
104{
105}
106
107// ----------------------------------------------------------------------------
108// wxTextCtrl-like methods
109// ----------------------------------------------------------------------------
110
111void wxSpinCtrl::SetValue(const wxString& text)
112{
113}
114
115int wxSpinCtrl::GetValue() const
116{
117 return 0;
118}
119
120void wxSpinCtrl::SetSelection(long from, long to)
121{
122}
123
124// ----------------------------------------------------------------------------
125// forward some methods to subcontrols
126// ----------------------------------------------------------------------------
127
128bool wxSpinCtrl::SetFont(const wxFont& font)
129{
130 return false;
131}
132
133bool wxSpinCtrl::Show(bool show)
134{
135 return false;
136}
137
138bool wxSpinCtrl::Enable(bool enable)
139{
140 return false;
141}
142
143void wxSpinCtrl::SetFocus()
144{
145}
146
147// ----------------------------------------------------------------------------
148// event processing
149// ----------------------------------------------------------------------------
150
151void wxSpinCtrl::OnSpinChange(wxSpinEvent& eventSpin)
152{
153}
154
155// ----------------------------------------------------------------------------
156// size calculations
157// ----------------------------------------------------------------------------
158
159wxSize wxSpinCtrl::DoGetBestSize() const
160{
161 return wxSize(0,0);
162}
163
164void wxSpinCtrl::DoMoveWindow(int x, int y, int width, int height)
165{
166}
167
168// get total size of the control
169void wxSpinCtrl::DoGetSize(int *x, int *y) const
170{
171}
172
173void wxSpinCtrl::DoGetPosition(int *x, int *y) const
174{
175}
176
177#endif // __WIN95__
178
179#endif
180 // wxUSE_SPINCTRL
181