compilation fixes for non default wxUSE_XXX values (patch 662781)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@18695 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1075,17 +1075,6 @@
|
||||
# endif
|
||||
#endif /* wxUSE_WXHTML_HELP */
|
||||
|
||||
#if wxUSE_PRINTING_ARCHITECTURE
|
||||
# if !wxUSE_COMBOBOX
|
||||
# ifdef wxABORT_ON_CONFIG_ERROR
|
||||
# error "Print dialog requires wxUSE_COMBOBOX"
|
||||
# else
|
||||
# undef wxUSE_COMBOBOX
|
||||
# define wxUSE_COMBOBOX 1
|
||||
# endif
|
||||
# endif
|
||||
#endif /* wxUSE_PRINTING_ARCHITECTURE */
|
||||
|
||||
#if wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
# if !wxUSE_MENUS
|
||||
# ifdef wxABORT_ON_CONFIG_ERROR
|
||||
@@ -1095,8 +1084,48 @@
|
||||
# define wxUSE_MENUS 1
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# if !wxUSE_STREAMS && !wxUSE_STD_IOSTREAM
|
||||
# ifdef wxABORT_ON_CONFIG_ERROR
|
||||
# error "DocView requires wxUSE_STREAMS or wxUSE_STD_IOSTREAM"
|
||||
# else
|
||||
# undef wxUSE_STREAMS
|
||||
# define wxUSE_STREAMS 1
|
||||
# endif
|
||||
# endif
|
||||
#endif /* wxUSE_DOC_VIEW_ARCHITECTURE */
|
||||
|
||||
#if wxUSE_PRINTING_ARCHITECTURE
|
||||
# if !wxUSE_COMBOBOX
|
||||
# ifdef wxABORT_ON_CONFIG_ERROR
|
||||
# error "Print dialog requires wxUSE_COMBOBOX"
|
||||
# else
|
||||
# undef wxUSE_COMBOBOX
|
||||
# define wxUSE_COMBOBOX 1
|
||||
# endif
|
||||
# endif
|
||||
|
||||
# if !wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
# ifdef wxABORT_ON_CONFIG_ERROR
|
||||
# error "Print architecture requires wxUSE_DOC_VIEW_ARCHITECTURE"
|
||||
# else
|
||||
# undef wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
# define wxUSE_DOC_VIEW_ARCHITECTURE 1
|
||||
# endif
|
||||
# endif
|
||||
#endif /* wxUSE_PRINTING_ARCHITECTURE */
|
||||
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
# if !wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
# ifdef wxABORT_ON_CONFIG_ERROR
|
||||
# error "MDI requires wxUSE_DOC_VIEW_ARCHITECTURE"
|
||||
# else
|
||||
# undef wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
# define wxUSE_DOC_VIEW_ARCHITECTURE 1
|
||||
# endif
|
||||
# endif
|
||||
#endif /* wxUSE_MDI_ARCHITECTURE */
|
||||
|
||||
#if !wxUSE_FILEDLG
|
||||
# if wxUSE_DOC_VIEW_ARCHITECTURE || wxUSE_WXHTML_HELP
|
||||
# ifdef wxABORT_ON_CONFIG_ERROR
|
||||
|
||||
@@ -602,7 +602,7 @@ public:
|
||||
float *descent = NULL, float *externalLeading = NULL,
|
||||
wxFont *theFont = NULL, bool use16bit = FALSE) const ;
|
||||
void GetSize(float* width, float* height) const { int w, h; GetSize(& w, & h); *width = w; *height = h; }
|
||||
void GetSizeMM(float *width, float *height) const { long w, h; GetSizeMM(& w, & h); *width = (float) w; *height = (float) h; }
|
||||
void GetSizeMM(float *width, float *height) const { int w, h; GetSizeMM(& w, & h); *width = (float) w; *height = (float) h; }
|
||||
|
||||
#endif // WXWIN_COMPATIBILITY
|
||||
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
#include "wx/defs.h"
|
||||
|
||||
#if wxUSE_MDI_ARCHITECTURE && wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
|
||||
#include "wx/docview.h"
|
||||
#include "wx/mdi.h"
|
||||
|
||||
@@ -17,6 +17,9 @@
|
||||
#endif
|
||||
|
||||
#include "wx/defs.h"
|
||||
|
||||
#if wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
|
||||
#include "wx/list.h"
|
||||
#include "wx/cmndata.h"
|
||||
#include "wx/string.h"
|
||||
@@ -586,6 +589,8 @@ bool WXDLLEXPORT wxTransferStreamToFile(wxSTD istream& stream, const wxString& f
|
||||
// converts from/to a stream to/from a temporary file.
|
||||
bool WXDLLEXPORT wxTransferFileToStream(const wxString& filename, wxOutputStream& stream);
|
||||
bool WXDLLEXPORT wxTransferStreamToFile(wxInputStream& stream, const wxString& filename);
|
||||
#endif
|
||||
#endif // wxUSE_STD_IOSTREAM
|
||||
|
||||
#endif // wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
|
||||
#endif // _WX_DOCH__
|
||||
|
||||
@@ -71,6 +71,17 @@ public:
|
||||
|
||||
virtual void DoSetVirtualSize(int x, int y);
|
||||
|
||||
#if WXWIN_COMPATIBILITY
|
||||
virtual void GetScrollUnitsPerPage(int *x_page, int *y_page) const;
|
||||
virtual void CalcUnscrolledPosition(int x, int y, float *xx, float *yy) const;
|
||||
// Need to do this otherwise the compiler gets confuced
|
||||
// between float and int calls to this function.
|
||||
void CalcUnscrolledPosition(int x, int y, int *xx, int *yy) const
|
||||
{ wxScrollHelper::CalcScrolledPosition(x, y, xx, yy); }
|
||||
wxPoint CalcUnscrolledPosition(const wxPoint& pt) const
|
||||
{ return wxScrollHelper::CalcScrolledPosition(pt); }
|
||||
#endif // WXWIN_COMPATIBILITY
|
||||
|
||||
protected:
|
||||
// this is needed for wxEVT_PAINT processing hack described in
|
||||
// wxScrollHelperEvtHandler::ProcessEvent()
|
||||
|
||||
@@ -91,8 +91,10 @@ public :
|
||||
inline bool operator==(const wxPoint2DInt& pt) const;
|
||||
inline bool operator!=(const wxPoint2DInt& pt) const;
|
||||
|
||||
#if wxUSE_STREAMS
|
||||
void WriteTo( wxDataOutputStream &stream ) const;
|
||||
void ReadFrom( wxDataInputStream &stream );
|
||||
#endif // wxUSE_STREAMS
|
||||
|
||||
wxInt32 m_x;
|
||||
wxInt32 m_y;
|
||||
@@ -738,8 +740,10 @@ public:
|
||||
bool operator == (const wxRect2DInt& rect) const;
|
||||
bool operator != (const wxRect2DInt& rect) const;
|
||||
|
||||
#if wxUSE_STREAMS
|
||||
void WriteTo( wxDataOutputStream &stream ) const;
|
||||
void ReadFrom( wxDataInputStream &stream );
|
||||
#endif // wxUSE_STREAMS
|
||||
|
||||
wxInt32 m_x;
|
||||
wxInt32 m_y;
|
||||
|
||||
@@ -537,6 +537,20 @@ inline void WXDLLEXPORT wxVLog##level(arg1, const wxChar *szFormat, \
|
||||
va_list argptr) {} \
|
||||
inline void WXDLLEXPORT wxLog##level(arg1, const wxChar *szFormat, ...) {}
|
||||
|
||||
// Empty Class to fake wxLogNull
|
||||
class WXDLLEXPORT wxLogNull
|
||||
{
|
||||
public:
|
||||
wxLogNull() {}
|
||||
};
|
||||
|
||||
// Dummy macros to replace some functions.
|
||||
#define wxSysErrorCode() (unsigned long)0
|
||||
#define wxSysErrorMsg( X ) (const wxChar*)NULL
|
||||
|
||||
// Fake symbolic trace masks... for those that are used frequently
|
||||
#define wxTRACE_OleCalls wxT("") // OLE interface calls
|
||||
|
||||
#endif // wxUSE_LOG/!wxUSE_LOG
|
||||
|
||||
// a generic function for all levels (level is passes as parameter)
|
||||
@@ -626,4 +640,3 @@ void WXDLLEXPORT wxSafeShowMessage(const wxString& title, const wxString& text);
|
||||
|
||||
#endif // _WX_LOG_H_
|
||||
|
||||
// vi:sts=4:sw=4:et
|
||||
|
||||
@@ -87,7 +87,6 @@ public:
|
||||
// --------------
|
||||
|
||||
// event handlers
|
||||
// bool OnClose();
|
||||
void OnCharHook(wxKeyEvent& event);
|
||||
void OnCloseWindow(wxCloseEvent& event);
|
||||
|
||||
|
||||
@@ -22,7 +22,7 @@ WXDLLEXPORT_DATA(extern const char*) wxDialogNameStr;
|
||||
class WXDLLEXPORT wxDialog : public wxDialogBase
|
||||
{
|
||||
DECLARE_DYNAMIC_CLASS(wxDialog)
|
||||
|
||||
|
||||
public:
|
||||
wxDialog();
|
||||
|
||||
@@ -49,49 +49,48 @@ public:
|
||||
{
|
||||
Create(parent, id, title, pos, size, style, name);
|
||||
}
|
||||
|
||||
|
||||
bool Create(wxWindow *parent, wxWindowID id,
|
||||
const wxString& title, // bool modal = FALSE, // TODO make this a window style?
|
||||
const wxPoint& pos = wxDefaultPosition,
|
||||
const wxSize& size = wxDefaultSize,
|
||||
long style = wxDEFAULT_DIALOG_STYLE,
|
||||
const wxString& name = wxDialogNameStr);
|
||||
|
||||
|
||||
~wxDialog();
|
||||
|
||||
|
||||
virtual bool Destroy();
|
||||
|
||||
virtual bool Show(bool show = TRUE);
|
||||
|
||||
void SetTitle(const wxString& title);
|
||||
|
||||
|
||||
void SetModal(bool flag);
|
||||
|
||||
|
||||
virtual bool IsModal() const
|
||||
{ return ((GetWindowStyleFlag() & wxDIALOG_MODAL) == wxDIALOG_MODAL); }
|
||||
|
||||
|
||||
virtual int ShowModal();
|
||||
virtual void EndModal(int retCode);
|
||||
|
||||
|
||||
// Implementation
|
||||
virtual void ChangeFont(bool keepOriginalSize = TRUE);
|
||||
virtual void ChangeBackgroundColour();
|
||||
virtual void ChangeForegroundColour();
|
||||
inline WXWidget GetTopWidget() const { return m_mainWidget; }
|
||||
inline WXWidget GetClientWidget() const { return m_mainWidget; }
|
||||
|
||||
|
||||
// Standard buttons
|
||||
void OnOK(wxCommandEvent& event);
|
||||
void OnApply(wxCommandEvent& event);
|
||||
void OnCancel(wxCommandEvent& event);
|
||||
|
||||
|
||||
// Responds to colour changes
|
||||
void OnSysColourChanged(wxSysColourChangedEvent& event);
|
||||
|
||||
// bool OnClose();
|
||||
|
||||
void OnCharHook(wxKeyEvent& event);
|
||||
void OnCloseWindow(wxCloseEvent& event);
|
||||
|
||||
|
||||
private:
|
||||
virtual bool DoCreate( wxWindow* parent, wxWindowID id,
|
||||
const wxString& title,
|
||||
@@ -108,9 +107,9 @@ protected:
|
||||
virtual void DoSetSize(int x, int y,
|
||||
int width, int height,
|
||||
int sizeFlags = wxSIZE_AUTO);
|
||||
|
||||
|
||||
virtual void DoSetClientSize(int width, int height);
|
||||
|
||||
|
||||
private:
|
||||
DECLARE_EVENT_TABLE()
|
||||
};
|
||||
|
||||
@@ -48,7 +48,7 @@ public:
|
||||
const wxString& name = wxButtonNameStr);
|
||||
|
||||
#if WXWIN_COMPATIBILITY
|
||||
wxBitmap *GetBitmap() const { return (wxBitmap *) & m_bmp; }
|
||||
wxBitmap *GetBitmap() const { return (wxBitmap *) &GetBitmapLabel(); }
|
||||
#endif
|
||||
|
||||
// Implementation
|
||||
|
||||
@@ -79,7 +79,6 @@ public:
|
||||
virtual bool Show(bool show = TRUE);
|
||||
|
||||
// event handlers
|
||||
bool OnClose();
|
||||
void OnCharHook(wxKeyEvent& event);
|
||||
void OnCloseWindow(wxCloseEvent& event);
|
||||
|
||||
|
||||
@@ -110,7 +110,6 @@ public:
|
||||
//
|
||||
// Event handlers
|
||||
//
|
||||
bool OnClose(void);
|
||||
void OnCharHook(wxKeyEvent& rEvent);
|
||||
void OnCloseWindow(wxCloseEvent& rEvent);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user