]> git.saurik.com Git - wxWidgets.git/blame - include/wx/os2/button.h
Fixed typo in my last commit (it did break socket detection code :-( ).
[wxWidgets.git] / include / wx / os2 / button.h
CommitLineData
0e320a79
DW
1/////////////////////////////////////////////////////////////////////////////
2// Name: button.h
3// Purpose: wxButton class
d88de032 4// Author: David Webster
0e320a79 5// Modified by:
d88de032 6// Created: 10/13/99
0e320a79 7// RCS-ID: $Id$
d88de032
DW
8// Copyright: (c) David Webster
9// Licence: wxWindows licence
0e320a79
DW
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_BUTTON_H_
13#define _WX_BUTTON_H_
14
0e320a79 15#include "wx/control.h"
0e320a79 16
0e320a79 17// Pushbutton
210a651b 18class WXDLLEXPORT wxButton: public wxButtonBase
0e320a79 19{
0e320a79 20 public:
afa59b4e
DW
21 inline wxButton() {}
22 inline wxButton( wxWindow* pParent
23 ,wxWindowID vId
24 ,const wxString& rsLabel
25 ,const wxPoint& rPos = wxDefaultPosition
26 ,const wxSize& rSize = wxDefaultSize
27 ,long lStyle = 0
57c4d796 28#if wxUSE_VALIDATORS
afa59b4e 29 ,const wxValidator& rValidator = wxDefaultValidator
57c4d796 30#endif
afa59b4e
DW
31 ,const wxString& rsName = wxButtonNameStr
32 )
33 {
34 Create( pParent
35 ,vId
36 ,rsLabel
37 ,rPos
38 ,rSize
39 ,lStyle
40#if wxUSE_VALIDATORS
41 ,rValidator
42#endif
43 ,rsName
44 );
45 }
0e320a79 46
afa59b4e
DW
47 bool Create( wxWindow* pParent
48 ,wxWindowID vId
49 ,const wxString& rsLabel
50 ,const wxPoint& rPos = wxDefaultPosition
51 ,const wxSize& rSize = wxDefaultSize
52 ,long lStyle = 0
57c4d796 53#if wxUSE_VALIDATORS
afa59b4e 54 ,const wxValidator& rValidator = wxDefaultValidator
57c4d796 55#endif
afa59b4e
DW
56 ,const wxString& rsName = wxButtonNameStr
57 );
0e320a79 58
afa59b4e 59 virtual ~wxButton();
1408104d 60
afa59b4e
DW
61 virtual void SetDefault(void);
62 static wxSize GetDefaultSize(void);
63 virtual void Command(wxCommandEvent& rEvent);
64 virtual bool OS2Command( WXUINT uParam
65 ,WXWORD vId
66 );
67 virtual WXHBRUSH OnCtlColor( WXHDC hDC
68 ,WXHWND hWnd
69 ,WXUINT uCtlColor
70 ,WXUINT uMessage
71 ,WXWPARAM wParam
72 ,WXLPARAM lParam
73 );
74 void MakeOwnerDrawn(void);
1408104d 75
afa59b4e
DW
76 virtual MRESULT WindowProc( WXUINT uMsg
77 ,WXWPARAM wParam
78 ,WXLPARAM lParam
79 );
1408104d 80
d88de032 81protected:
d88de032 82
afa59b4e
DW
83 bool SendClickEvent(void);
84 virtual wxSize DoGetBestSize(void) const;
210a651b
DW
85private:
86 DECLARE_DYNAMIC_CLASS(wxButton)
afa59b4e 87}; // end of CLASS wxButton
0e320a79
DW
88
89#endif
90 // _WX_BUTTON_H_
afa59b4e 91