]> git.saurik.com Git - wxWidgets.git/blame - src/common/spinbtncmn.cpp
remove run-time check for now-required GTK 2.4
[wxWidgets.git] / src / common / spinbtncmn.cpp
CommitLineData
e1d3601a
PC
1/////////////////////////////////////////////////////////////////////////////
2// Name: src/common/spinbtncmn.cpp
3// Purpose: wxSpinButton common code
4// Author: Julian Smart
5// Modified by:
6// Created: 04/01/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12// ============================================================================
13// declarations
14// ============================================================================
15
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/app.h"
29#endif
30
31#if wxUSE_SPINBTN
32
33#include "wx/spinbutt.h"
34
35// ----------------------------------------------------------------------------
36// XTI
37// ----------------------------------------------------------------------------
38
39wxDEFINE_FLAGS( wxSpinButtonStyle )
40wxBEGIN_FLAGS( wxSpinButtonStyle )
41 // new style border flags, we put them first to
42 // use them for streaming out
43 wxFLAGS_MEMBER(wxBORDER_SIMPLE)
44 wxFLAGS_MEMBER(wxBORDER_SUNKEN)
45 wxFLAGS_MEMBER(wxBORDER_DOUBLE)
46 wxFLAGS_MEMBER(wxBORDER_RAISED)
47 wxFLAGS_MEMBER(wxBORDER_STATIC)
48 wxFLAGS_MEMBER(wxBORDER_NONE)
49
50 // old style border flags
51 wxFLAGS_MEMBER(wxSIMPLE_BORDER)
52 wxFLAGS_MEMBER(wxSUNKEN_BORDER)
53 wxFLAGS_MEMBER(wxDOUBLE_BORDER)
54 wxFLAGS_MEMBER(wxRAISED_BORDER)
55 wxFLAGS_MEMBER(wxSTATIC_BORDER)
56 wxFLAGS_MEMBER(wxBORDER)
57
58 // standard window styles
59 wxFLAGS_MEMBER(wxTAB_TRAVERSAL)
60 wxFLAGS_MEMBER(wxCLIP_CHILDREN)
61 wxFLAGS_MEMBER(wxTRANSPARENT_WINDOW)
62 wxFLAGS_MEMBER(wxWANTS_CHARS)
63 wxFLAGS_MEMBER(wxFULL_REPAINT_ON_RESIZE)
64 wxFLAGS_MEMBER(wxALWAYS_SHOW_SB )
65 wxFLAGS_MEMBER(wxVSCROLL)
66 wxFLAGS_MEMBER(wxHSCROLL)
67
68 wxFLAGS_MEMBER(wxSP_HORIZONTAL)
69 wxFLAGS_MEMBER(wxSP_VERTICAL)
70 wxFLAGS_MEMBER(wxSP_ARROW_KEYS)
71 wxFLAGS_MEMBER(wxSP_WRAP)
72wxEND_FLAGS( wxSpinButtonStyle )
73
88a4f868 74wxIMPLEMENT_DYNAMIC_CLASS_XTI(wxSpinButton, wxControl, "wx/spinbutt.h")
e1d3601a
PC
75
76wxBEGIN_PROPERTIES_TABLE(wxSpinButton)
77 wxEVENT_RANGE_PROPERTY( Spin, wxEVT_SCROLL_TOP, wxEVT_SCROLL_CHANGED, wxSpinEvent )
78
79 wxPROPERTY( Value, int, SetValue, GetValue, 0, 0 /*flags*/, \
80 wxT("Helpstring"), wxT("group"))
81 wxPROPERTY( Min, int, SetMin, GetMin, 0, 0 /*flags*/, \
82 wxT("Helpstring"), wxT("group"))
83 wxPROPERTY( Max, int, SetMax, GetMax, 0, 0 /*flags*/, \
84 wxT("Helpstring"), wxT("group"))
85
86 wxPROPERTY_FLAGS( WindowStyle, wxSpinButtonStyle, long, SetWindowStyleFlag, \
87 GetWindowStyleFlag, wxEMPTY_PARAMETER_VALUE, 0 /*flags*/, \
88 wxT("Helpstring"), wxT("group")) // style
89wxEND_PROPERTIES_TABLE()
90
91wxEMPTY_HANDLERS_TABLE(wxSpinButton)
92
93wxCONSTRUCTOR_5( wxSpinButton, wxWindow*, Parent, wxWindowID, Id, \
94 wxPoint, Position, wxSize, Size, long, WindowStyle )
95
96IMPLEMENT_DYNAMIC_CLASS(wxSpinEvent, wxNotifyEvent)
97
98
99#endif // wxUSE_SPINBTN