]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/os2/button.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxButton class
4 // Author: David Webster
8 // Copyright: (c) David Webster
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
15 #include "wx/control.h"
17 WXDLLEXPORT_DATA(extern const char*) wxButtonNameStr
;
20 class WXDLLEXPORT wxButton
: public wxControl
22 DECLARE_DYNAMIC_CLASS(wxButton
)
25 inline wxButton(wxWindow
*parent
, wxWindowID id
, const wxString
& label
,
26 const wxPoint
& pos
= wxDefaultPosition
,
27 const wxSize
& size
= wxDefaultSize
, long style
= 0,
29 const wxValidator
& validator
= wxDefaultValidator
,
31 const wxString
& name
= wxButtonNameStr
)
33 Create(parent
, id
, label
, pos
, size
, style
, validator
, name
);
36 bool Create(wxWindow
*parent
, wxWindowID id
, const wxString
& label
,
37 const wxPoint
& pos
= wxDefaultPosition
,
38 const wxSize
& size
= wxDefaultSize
, long style
= 0,
40 const wxValidator
& validator
= wxDefaultValidator
,
42 const wxString
& name
= wxButtonNameStr
);
46 virtual void SetDefault();
48 static wxSize
GetDefaultSize();
50 virtual void Command(wxCommandEvent
& event
);
51 virtual bool OS2Command(WXUINT param
, WXWORD id
);
52 virtual WXHBRUSH
OnCtlColor(WXHDC pDC
,
59 // send a notification event, return TRUE if processed
60 bool SendClickEvent();
62 virtual wxSize
DoGetBestSize() const;