]> git.saurik.com Git - wxWidgets.git/blame - include/wx/os2/button.h
use iostream.h and not iostream with OpenWatcom (part of patch 910058)
[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
afa59b4e 28 ,const wxValidator& rValidator = wxDefaultValidator
afa59b4e
DW
29 ,const wxString& rsName = wxButtonNameStr
30 )
31 {
32 Create( pParent
33 ,vId
34 ,rsLabel
35 ,rPos
36 ,rSize
37 ,lStyle
afa59b4e 38 ,rValidator
afa59b4e
DW
39 ,rsName
40 );
41 }
0e320a79 42
afa59b4e
DW
43 bool Create( wxWindow* pParent
44 ,wxWindowID vId
45 ,const wxString& rsLabel
46 ,const wxPoint& rPos = wxDefaultPosition
47 ,const wxSize& rSize = wxDefaultSize
48 ,long lStyle = 0
afa59b4e 49 ,const wxValidator& rValidator = wxDefaultValidator
afa59b4e
DW
50 ,const wxString& rsName = wxButtonNameStr
51 );
0e320a79 52
afa59b4e 53 virtual ~wxButton();
1408104d 54
afa59b4e
DW
55 virtual void SetDefault(void);
56 static wxSize GetDefaultSize(void);
57 virtual void Command(wxCommandEvent& rEvent);
58 virtual bool OS2Command( WXUINT uParam
59 ,WXWORD vId
60 );
61 virtual WXHBRUSH OnCtlColor( WXHDC hDC
62 ,WXHWND hWnd
63 ,WXUINT uCtlColor
64 ,WXUINT uMessage
65 ,WXWPARAM wParam
66 ,WXLPARAM lParam
67 );
68 void MakeOwnerDrawn(void);
1408104d 69
afa59b4e
DW
70 virtual MRESULT WindowProc( WXUINT uMsg
71 ,WXWPARAM wParam
72 ,WXLPARAM lParam
73 );
1408104d 74
d88de032 75protected:
d88de032 76
b9b1d6c8 77 bool SendClickEvent(void);
430974f8
DW
78 void SetTmpDefault(void);
79 void UnsetTmpDefault(void);
80
018d3030
DW
81 static void SetDefaultStyle( wxButton* pButton
82 ,bool bOn
83 );
430974f8 84
b9b1d6c8
DW
85 virtual wxSize DoGetBestSize(void) const;
86 virtual WXDWORD OS2GetStyle( long style
87 ,WXDWORD* exstyle
88 ) const;
210a651b
DW
89private:
90 DECLARE_DYNAMIC_CLASS(wxButton)
afa59b4e 91}; // end of CLASS wxButton
0e320a79
DW
92
93#endif
94 // _WX_BUTTON_H_
afa59b4e 95