Some OS/2 Modifications

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@12145 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
David Webster 2001-10-22 05:11:09 +00:00
parent 8766aa0948
commit afa59b4e88
8 changed files with 75 additions and 42 deletions

View File

@ -70,7 +70,7 @@
// using this macro allows constuctions like "wxSTD iostream" to work in
// either case
#if !wxUSE_IOSTREAMH
#define wxSTD std::
#define wxSTD std::
#else
#define wxSTD
#endif
@ -1951,7 +1951,7 @@ typedef struct tagLOGPALETTE
#elif defined(__WIN32__)
typedef int (__stdcall *WXFARPROC)();
#elif defined(__WXPM__)
# if (defined(__VISAGECPP__) && (__IBMCPP__ < 400 || __IBMC__ < 400 )) || defined (__WATCOMC__)
# if (defined(__VISAGECPP__) && (__IBMCPP__ < 400)) || defined (__WATCOMC__)
// VA 3.0 for some reason needs base data types when typedefing a proc proto???
typedef void* (_System *WXFARPROC)(unsigned long, unsigned long, void*, void*);
# else

View File

@ -20,48 +20,74 @@ WXDLLEXPORT_DATA(extern const char*) wxButtonNameStr;
class WXDLLEXPORT wxButton: public wxButtonBase
{
public:
inline wxButton() {}
inline wxButton(wxWindow *parent, wxWindowID id, const wxString& label,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize, long style = 0,
inline wxButton() {}
inline wxButton( wxWindow* pParent
,wxWindowID vId
,const wxString& rsLabel
,const wxPoint& rPos = wxDefaultPosition
,const wxSize& rSize = wxDefaultSize
,long lStyle = 0
#if wxUSE_VALIDATORS
const wxValidator& validator = wxDefaultValidator,
,const wxValidator& rValidator = wxDefaultValidator
#endif
const wxString& name = wxButtonNameStr)
{
Create(parent, id, label, pos, size, style, validator, name);
}
bool Create(wxWindow *parent, wxWindowID id, const wxString& label,
const wxPoint& pos = wxDefaultPosition,
const wxSize& size = wxDefaultSize, long style = 0,
,const wxString& rsName = wxButtonNameStr
)
{
Create( pParent
,vId
,rsLabel
,rPos
,rSize
,lStyle
#if wxUSE_VALIDATORS
const wxValidator& validator = wxDefaultValidator,
,rValidator
#endif
const wxString& name = wxButtonNameStr);
,rsName
);
}
virtual ~wxButton();
bool Create( wxWindow* pParent
,wxWindowID vId
,const wxString& rsLabel
,const wxPoint& rPos = wxDefaultPosition
,const wxSize& rSize = wxDefaultSize
,long lStyle = 0
#if wxUSE_VALIDATORS
,const wxValidator& rValidator = wxDefaultValidator
#endif
,const wxString& rsName = wxButtonNameStr
);
virtual void SetDefault();
virtual ~wxButton();
static wxSize GetDefaultSize();
virtual void SetDefault(void);
static wxSize GetDefaultSize(void);
virtual void Command(wxCommandEvent& rEvent);
virtual bool OS2Command( WXUINT uParam
,WXWORD vId
);
virtual WXHBRUSH OnCtlColor( WXHDC hDC
,WXHWND hWnd
,WXUINT uCtlColor
,WXUINT uMessage
,WXWPARAM wParam
,WXLPARAM lParam
);
void MakeOwnerDrawn(void);
virtual MRESULT WindowProc( WXUINT uMsg
,WXWPARAM wParam
,WXLPARAM lParam
);
virtual void Command(wxCommandEvent& event);
virtual bool OS2Command(WXUINT param, WXWORD id);
virtual WXHBRUSH OnCtlColor(WXHDC pDC,
WXHWND pWnd,
WXUINT nCtlColor,
WXUINT message,
WXWPARAM wParam,
WXLPARAM lParam);
protected:
// send a notification event, return TRUE if processed
bool SendClickEvent();
virtual wxSize DoGetBestSize() const;
bool SendClickEvent(void);
virtual wxSize DoGetBestSize(void) const;
private:
DECLARE_DYNAMIC_CLASS(wxButton)
};
}; // end of CLASS wxButton
#endif
// _WX_BUTTON_H_

View File

@ -106,7 +106,7 @@ protected:
wxFunction m_callback; // Callback associated with the window
#endif // WXWIN_COMPATIBILITY
protected:
public:
//
// For controls like radiobuttons which are really composite
//
@ -132,7 +132,14 @@ protected:
//
WXDWORD GetExStyle(WXDWORD& rStyle) const;
inline int GetXComp(void) const {return m_nXComp;}
inline int GetYComp(void) const {return m_nYComp;}
inline void SetXComp(const int nXComp) {m_nXComp = nXComp;}
inline void SetYComp(const int nYComp) {m_nYComp = nYComp;}
private:
int m_nXComp;
int m_nYComp;
DECLARE_EVENT_TABLE()
}; // end of wxControl

View File

@ -41,7 +41,7 @@ public:
{
long lModalStyle = lStyle ? wxDIALOG_MODAL : wxDIALOG_MODELESS ;
bModal = false;
bModal = FALSE;
Create( pParent
,-1
,rsTitle

View File

@ -66,6 +66,7 @@ public:
// implementation only from now on
// -------------------------------
void AlterChildPos(void);
// override some more virtuals
virtual bool Show(bool bShow = TRUE);

View File

@ -366,5 +366,8 @@
#define wxUSE_CMDLINE_PARSER 1
#define wxUSE_SPLASH 1
#define NO_TEXT_WINDOW_STREAM 1
#endif
// _WX_SETUP_H_

View File

@ -368,11 +368,7 @@ public:
bool HandleSysCommand( WXWPARAM wParam
,WXLPARAM lParam
);
bool HandleWindowParams( PWNDPARAMS pParams
,WXLPARAM lParam
);
bool HandlePaletteChanged();
bool HandlePresParamChanged(WXWPARAM wParam);
bool HandleSysColorChange(void);
bool HandleCtlColor(WXHBRUSH* hBrush);
bool HandleSetFocus(WXHWND hWnd);
@ -387,14 +383,14 @@ public:
,int nY
,WXUINT uFlags
);
bool HandleChar( WXWORD wParam
bool HandleChar( WXDWORD wParam
,WXLPARAM lParam
,bool bIsASCII = FALSE
);
bool HandleKeyDown( WXWORD wParam
,WXLPARAM lParam
);
bool HandleKeyUp( WXWORD wParam
bool HandleKeyUp( WXDWORD wParam
,WXLPARAM lParam
);
bool HandleQueryDragIcon(WXHICON* phIcon);

View File

@ -281,8 +281,8 @@ typedef _TUCHAR wxUChar;
# define wxUSE_WCHAR_T 0
# elif defined(__WATCOMC__)
# define wxUSE_WCHAR_T 0
# elif defined(__VISAGECPP__) && (__IBMCPP__ >= 400)
# define wxUSE_WCHAR_T 1
# elif defined(__VISAGECPP__) && (__IBMCPP__ < 400)
# define wxUSE_WCHAR_T 0
# else
// add additional compiler checks if this fails
# define wxUSE_WCHAR_T 1