@@ -105,7 +105,7 @@ public:
|
|||||||
for ( size_t n = 0; n < src.size(); n++ )
|
for ( size_t n = 0; n < src.size(); n++ )
|
||||||
Add(src[n]);
|
Add(src[n]);
|
||||||
}
|
}
|
||||||
wxEXPLICIT wxSortedArrayString(wxArrayString::CompareFunction compareFunction)
|
explicit wxSortedArrayString(wxArrayString::CompareFunction compareFunction)
|
||||||
: wxSortedArrayStringBase(compareFunction)
|
: wxSortedArrayStringBase(compareFunction)
|
||||||
{ }
|
{ }
|
||||||
|
|
||||||
@@ -151,7 +151,7 @@ public:
|
|||||||
// wouldn't be needed if the 'explicit' keyword was supported by all
|
// wouldn't be needed if the 'explicit' keyword was supported by all
|
||||||
// compilers, or if this was protected ctor for wxSortedArrayString,
|
// compilers, or if this was protected ctor for wxSortedArrayString,
|
||||||
// but we're stuck with it now.
|
// but we're stuck with it now.
|
||||||
wxEXPLICIT wxArrayString(int autoSort) { Init(autoSort != 0); }
|
explicit wxArrayString(int autoSort) { Init(autoSort != 0); }
|
||||||
// C string array ctor
|
// C string array ctor
|
||||||
wxArrayString(size_t sz, const char** a);
|
wxArrayString(size_t sz, const char** a);
|
||||||
wxArrayString(size_t sz, const wchar_t** a);
|
wxArrayString(size_t sz, const wchar_t** a);
|
||||||
@@ -263,7 +263,7 @@ public:
|
|||||||
public:
|
public:
|
||||||
pointer m_ptr;
|
pointer m_ptr;
|
||||||
reverse_iterator() : m_ptr(NULL) { }
|
reverse_iterator() : m_ptr(NULL) { }
|
||||||
wxEXPLICIT reverse_iterator(pointer ptr) : m_ptr(ptr) { }
|
explicit reverse_iterator(pointer ptr) : m_ptr(ptr) { }
|
||||||
reverse_iterator(const itor& it) : m_ptr(it.m_ptr) { }
|
reverse_iterator(const itor& it) : m_ptr(it.m_ptr) { }
|
||||||
reference operator*() const { return *m_ptr; }
|
reference operator*() const { return *m_ptr; }
|
||||||
pointer operator->() const { return m_ptr; }
|
pointer operator->() const { return m_ptr; }
|
||||||
@@ -289,7 +289,7 @@ public:
|
|||||||
public:
|
public:
|
||||||
pointer m_ptr;
|
pointer m_ptr;
|
||||||
const_reverse_iterator() : m_ptr(NULL) { }
|
const_reverse_iterator() : m_ptr(NULL) { }
|
||||||
wxEXPLICIT const_reverse_iterator(pointer ptr) : m_ptr(ptr) { }
|
explicit const_reverse_iterator(pointer ptr) : m_ptr(ptr) { }
|
||||||
const_reverse_iterator(const itor& it) : m_ptr(it.m_ptr) { }
|
const_reverse_iterator(const itor& it) : m_ptr(it.m_ptr) { }
|
||||||
const_reverse_iterator(const reverse_iterator& it) : m_ptr(it.m_ptr) { }
|
const_reverse_iterator(const reverse_iterator& it) : m_ptr(it.m_ptr) { }
|
||||||
reference operator*() const { return *m_ptr; }
|
reference operator*() const { return *m_ptr; }
|
||||||
@@ -389,7 +389,7 @@ public:
|
|||||||
wxSortedArrayString(const wxArrayString& array) : wxArrayString(true)
|
wxSortedArrayString(const wxArrayString& array) : wxArrayString(true)
|
||||||
{ Copy(array); }
|
{ Copy(array); }
|
||||||
|
|
||||||
wxEXPLICIT wxSortedArrayString(CompareFunction compareFunction)
|
explicit wxSortedArrayString(CompareFunction compareFunction)
|
||||||
: wxArrayString(true)
|
: wxArrayString(true)
|
||||||
{ m_compareFunction = compareFunction; }
|
{ m_compareFunction = compareFunction; }
|
||||||
};
|
};
|
||||||
|
@@ -87,7 +87,7 @@ class wxDataViewItem : public wxItemId<void*>
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxDataViewItem() : wxItemId<void*>() { }
|
wxDataViewItem() : wxItemId<void*>() { }
|
||||||
wxEXPLICIT wxDataViewItem(void* pItem) : wxItemId<void*>(pItem) { }
|
explicit wxDataViewItem(void* pItem) : wxItemId<void*>(pItem) { }
|
||||||
};
|
};
|
||||||
|
|
||||||
WX_DEFINE_ARRAY(wxDataViewItem, wxDataViewItemArray);
|
WX_DEFINE_ARRAY(wxDataViewItem, wxDataViewItemArray);
|
||||||
|
@@ -229,23 +229,8 @@ typedef short int WXTYPE;
|
|||||||
/* wrap it in this guard, but such cases should still be relatively rare. */
|
/* wrap it in this guard, but such cases should still be relatively rare. */
|
||||||
#define wxUSE_NESTED_CLASSES 1
|
#define wxUSE_NESTED_CLASSES 1
|
||||||
|
|
||||||
/* check for explicit keyword support */
|
/* This macro is obsolete, use the 'explicit' keyword in the new code. */
|
||||||
#ifndef HAVE_EXPLICIT
|
#define wxEXPLICIT explicit
|
||||||
#if defined(__VISUALC__)
|
|
||||||
#define HAVE_EXPLICIT
|
|
||||||
#elif defined(__GNUC__)
|
|
||||||
#define HAVE_EXPLICIT
|
|
||||||
#elif defined(__BORLANDC__) && (__BORLANDC__ >= 0x0520)
|
|
||||||
/* BC++ 4.52 doesn't support explicit, CBuilder 1 does */
|
|
||||||
#define HAVE_EXPLICIT
|
|
||||||
#endif
|
|
||||||
#endif /* !HAVE_EXPLICIT */
|
|
||||||
|
|
||||||
#ifdef HAVE_EXPLICIT
|
|
||||||
#define wxEXPLICIT explicit
|
|
||||||
#else /* !HAVE_EXPLICIT */
|
|
||||||
#define wxEXPLICIT
|
|
||||||
#endif /* HAVE_EXPLICIT/!HAVE_EXPLICIT */
|
|
||||||
|
|
||||||
/* check for override keyword support */
|
/* check for override keyword support */
|
||||||
#ifndef HAVE_OVERRIDE
|
#ifndef HAVE_OVERRIDE
|
||||||
|
@@ -739,7 +739,7 @@ public:
|
|||||||
{ return it.m_node == m_node; }
|
{ return it.m_node == m_node; }
|
||||||
};
|
};
|
||||||
|
|
||||||
wxEXPLICIT wxDList(size_type n, const_reference v = value_type())
|
explicit wxDList(size_type n, const_reference v = value_type())
|
||||||
{ assign(n, v); }
|
{ assign(n, v); }
|
||||||
wxDList(const const_iterator& first, const const_iterator& last)
|
wxDList(const const_iterator& first, const const_iterator& last)
|
||||||
{ assign(first, last); }
|
{ assign(first, last); }
|
||||||
|
@@ -123,9 +123,9 @@ public:
|
|||||||
{ InitPointSize(-1); }
|
{ InitPointSize(-1); }
|
||||||
|
|
||||||
// These ctors specify the font size, either in points or in pixels.
|
// These ctors specify the font size, either in points or in pixels.
|
||||||
wxEXPLICIT wxFontInfo(int pointSize)
|
explicit wxFontInfo(int pointSize)
|
||||||
{ InitPointSize(pointSize); }
|
{ InitPointSize(pointSize); }
|
||||||
wxEXPLICIT wxFontInfo(const wxSize& pixelSize) : m_pixelSize(pixelSize)
|
explicit wxFontInfo(const wxSize& pixelSize) : m_pixelSize(pixelSize)
|
||||||
{ Init(); }
|
{ Init(); }
|
||||||
|
|
||||||
// Setters for the various attributes. All of them return the object itself
|
// Setters for the various attributes. All of them return the object itself
|
||||||
|
@@ -53,7 +53,7 @@ private:
|
|||||||
class WXDLLIMPEXP_ADV wxGridCellTextEditor : public wxGridCellEditor
|
class WXDLLIMPEXP_ADV wxGridCellTextEditor : public wxGridCellEditor
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxGridCellTextEditor(size_t maxChars = 0);
|
explicit wxGridCellTextEditor(size_t maxChars = 0);
|
||||||
|
|
||||||
virtual void Create(wxWindow* parent,
|
virtual void Create(wxWindow* parent,
|
||||||
wxWindowID id,
|
wxWindowID id,
|
||||||
|
@@ -17,9 +17,9 @@
|
|||||||
class wxTextMeasure : public wxTextMeasureBase
|
class wxTextMeasure : public wxTextMeasureBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxTextMeasure(const wxDC *dc, const wxFont *font = NULL)
|
explicit wxTextMeasure(const wxDC *dc, const wxFont *font = NULL)
|
||||||
: wxTextMeasureBase(dc, font) {}
|
: wxTextMeasureBase(dc, font) {}
|
||||||
wxEXPLICIT wxTextMeasure(const wxWindow *win, const wxFont *font = NULL)
|
explicit wxTextMeasure(const wxWindow *win, const wxFont *font = NULL)
|
||||||
: wxTextMeasureBase(win, font) {}
|
: wxTextMeasureBase(win, font) {}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
@@ -82,7 +82,7 @@ public:
|
|||||||
wxBitmap(const wxImage& image, int depth = wxBITMAP_SCREEN_DEPTH, double scale = 1.0);
|
wxBitmap(const wxImage& image, int depth = wxBITMAP_SCREEN_DEPTH, double scale = 1.0);
|
||||||
#endif // wxUSE_IMAGE
|
#endif // wxUSE_IMAGE
|
||||||
wxBitmap(GdkPixbuf* pixbuf, int depth = 0);
|
wxBitmap(GdkPixbuf* pixbuf, int depth = 0);
|
||||||
wxEXPLICIT wxBitmap(const wxCursor& cursor);
|
explicit wxBitmap(const wxCursor& cursor);
|
||||||
virtual ~wxBitmap();
|
virtual ~wxBitmap();
|
||||||
|
|
||||||
bool Create(int width, int height, int depth = wxBITMAP_SCREEN_DEPTH) wxOVERRIDE;
|
bool Create(int width, int height, int depth = wxBITMAP_SCREEN_DEPTH) wxOVERRIDE;
|
||||||
|
@@ -29,7 +29,7 @@ public:
|
|||||||
const wxString& name = wxGLCanvasName,
|
const wxString& name = wxGLCanvasName,
|
||||||
const wxPalette& palette = wxNullPalette);
|
const wxPalette& palette = wxNullPalette);
|
||||||
|
|
||||||
wxEXPLICIT // avoid implicitly converting a wxWindow* to wxGLCanvas
|
explicit // avoid implicitly converting a wxWindow* to wxGLCanvas
|
||||||
wxGLCanvas(wxWindow *parent,
|
wxGLCanvas(wxWindow *parent,
|
||||||
wxWindowID id = wxID_ANY,
|
wxWindowID id = wxID_ANY,
|
||||||
const int *attribList = NULL,
|
const int *attribList = NULL,
|
||||||
|
@@ -19,13 +19,13 @@ class WXDLLIMPEXP_FWD_CORE wxWindowDCImpl;
|
|||||||
class wxTextMeasure : public wxTextMeasureBase
|
class wxTextMeasure : public wxTextMeasureBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxTextMeasure(const wxDC *dc, const wxFont *font = NULL)
|
explicit wxTextMeasure(const wxDC *dc, const wxFont *font = NULL)
|
||||||
: wxTextMeasureBase(dc, font)
|
: wxTextMeasureBase(dc, font)
|
||||||
{
|
{
|
||||||
Init();
|
Init();
|
||||||
}
|
}
|
||||||
|
|
||||||
wxEXPLICIT wxTextMeasure(const wxWindow *win, const wxFont *font = NULL)
|
explicit wxTextMeasure(const wxWindow *win, const wxFont *font = NULL)
|
||||||
: wxTextMeasureBase(win, font)
|
: wxTextMeasureBase(win, font)
|
||||||
{
|
{
|
||||||
Init();
|
Init();
|
||||||
|
@@ -29,7 +29,7 @@ public:
|
|||||||
const wxString& name = wxGLCanvasName,
|
const wxString& name = wxGLCanvasName,
|
||||||
const wxPalette& palette = wxNullPalette);
|
const wxPalette& palette = wxNullPalette);
|
||||||
|
|
||||||
wxEXPLICIT // avoid implicitly converting a wxWindow* to wxGLCanvas
|
explicit // avoid implicitly converting a wxWindow* to wxGLCanvas
|
||||||
wxGLCanvas(wxWindow *parent,
|
wxGLCanvas(wxWindow *parent,
|
||||||
wxWindowID id = wxID_ANY,
|
wxWindowID id = wxID_ANY,
|
||||||
const int *attribList = NULL,
|
const int *attribList = NULL,
|
||||||
|
@@ -640,8 +640,8 @@ public: \
|
|||||||
typedef VALUE_T mapped_type; \
|
typedef VALUE_T mapped_type; \
|
||||||
_WX_DECLARE_PAIR( iterator, bool, Insert_Result, CLASSEXP ) \
|
_WX_DECLARE_PAIR( iterator, bool, Insert_Result, CLASSEXP ) \
|
||||||
\
|
\
|
||||||
wxEXPLICIT CLASSNAME( size_type hint = 100, hasher hf = hasher(), \
|
explicit CLASSNAME( size_type hint = 100, hasher hf = hasher(), \
|
||||||
key_equal eq = key_equal() ) \
|
key_equal eq = key_equal() ) \
|
||||||
: CLASSNAME##_wxImplementation_HashTable( hint, hf, eq, \
|
: CLASSNAME##_wxImplementation_HashTable( hint, hf, eq, \
|
||||||
CLASSNAME##_wxImplementation_KeyEx() ) {} \
|
CLASSNAME##_wxImplementation_KeyEx() ) {} \
|
||||||
\
|
\
|
||||||
|
@@ -123,8 +123,8 @@ CLASSEXP CLASSNAME:public CLASSNAME##_wxImplementation_HashTable \
|
|||||||
public: \
|
public: \
|
||||||
_WX_DECLARE_PAIR( iterator, bool, Insert_Result, CLASSEXP ) \
|
_WX_DECLARE_PAIR( iterator, bool, Insert_Result, CLASSEXP ) \
|
||||||
\
|
\
|
||||||
wxEXPLICIT CLASSNAME( size_type hint = 100, hasher hf = hasher(), \
|
explicit CLASSNAME( size_type hint = 100, hasher hf = hasher(), \
|
||||||
key_equal eq = key_equal() ) \
|
key_equal eq = key_equal() ) \
|
||||||
: CLASSNAME##_wxImplementation_HashTable( hint, hf, eq, \
|
: CLASSNAME##_wxImplementation_HashTable( hint, hf, eq, \
|
||||||
CLASSNAME##_wxImplementation_KeyEx() ) {} \
|
CLASSNAME##_wxImplementation_KeyEx() ) {} \
|
||||||
\
|
\
|
||||||
|
@@ -21,7 +21,7 @@ class WXDLLIMPEXP_BASE wxIconLocationBase
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
// ctor takes the name of the file where the icon is
|
// ctor takes the name of the file where the icon is
|
||||||
wxEXPLICIT wxIconLocationBase(const wxString& filename = wxEmptyString)
|
explicit wxIconLocationBase(const wxString& filename = wxEmptyString)
|
||||||
: m_filename(filename) { }
|
: m_filename(filename) { }
|
||||||
|
|
||||||
// default copy ctor, assignment operator and dtor are ok
|
// default copy ctor, assignment operator and dtor are ok
|
||||||
@@ -47,7 +47,7 @@ class WXDLLIMPEXP_BASE wxIconLocation : public wxIconLocationBase
|
|||||||
public:
|
public:
|
||||||
// ctor takes the name of the file where the icon is and the icons index in
|
// ctor takes the name of the file where the icon is and the icons index in
|
||||||
// the file
|
// the file
|
||||||
wxEXPLICIT wxIconLocation(const wxString& file = wxEmptyString, int num = 0);
|
explicit wxIconLocation(const wxString& file = wxEmptyString, int num = 0);
|
||||||
|
|
||||||
// set/get the icon index
|
// set/get the icon index
|
||||||
void SetIndex(int num) { m_index = num; }
|
void SetIndex(int num) { m_index = num; }
|
||||||
@@ -70,7 +70,7 @@ wxIconLocation::wxIconLocation(const wxString& file, int num)
|
|||||||
class WXDLLIMPEXP_BASE wxIconLocation : public wxIconLocationBase
|
class WXDLLIMPEXP_BASE wxIconLocation : public wxIconLocationBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxIconLocation(const wxString& filename = wxEmptyString)
|
explicit wxIconLocation(const wxString& filename = wxEmptyString)
|
||||||
: wxIconLocationBase(filename) { }
|
: wxIconLocationBase(filename) { }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@@ -942,7 +942,7 @@ private:
|
|||||||
{ return it.m_node == m_node; } \
|
{ return it.m_node == m_node; } \
|
||||||
}; \
|
}; \
|
||||||
\
|
\
|
||||||
wxEXPLICIT name(size_type n, const_reference v = value_type()) \
|
explicit name(size_type n, const_reference v = value_type()) \
|
||||||
{ assign(n, v); } \
|
{ assign(n, v); } \
|
||||||
name(const const_iterator& first, const const_iterator& last) \
|
name(const const_iterator& first, const const_iterator& last) \
|
||||||
{ assign(first, last); } \
|
{ assign(first, last); } \
|
||||||
|
@@ -77,7 +77,7 @@ private:
|
|||||||
class wxModalDialogHookExitGuard
|
class wxModalDialogHookExitGuard
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxModalDialogHookExitGuard(wxDialog* dialog)
|
explicit wxModalDialogHookExitGuard(wxDialog* dialog)
|
||||||
: m_dialog(dialog)
|
: m_dialog(dialog)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@@ -98,7 +98,7 @@ public:
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Convert from wxCursor
|
// Convert from wxCursor
|
||||||
wxEXPLICIT wxBitmap(const wxCursor& cursor)
|
explicit wxBitmap(const wxCursor& cursor)
|
||||||
{
|
{
|
||||||
(void)CopyFromCursor(cursor, wxBitmapTransparency_Auto);
|
(void)CopyFromCursor(cursor, wxBitmapTransparency_Auto);
|
||||||
}
|
}
|
||||||
|
@@ -96,7 +96,7 @@ public:
|
|||||||
|
|
||||||
// as above, but takes reference DC as first argument to take resolution,
|
// as above, but takes reference DC as first argument to take resolution,
|
||||||
// size, font metrics etc. from
|
// size, font metrics etc. from
|
||||||
wxEXPLICIT
|
explicit
|
||||||
wxEnhMetaFileDC(const wxDC& referenceDC,
|
wxEnhMetaFileDC(const wxDC& referenceDC,
|
||||||
const wxString& filename = wxEmptyString,
|
const wxString& filename = wxEmptyString,
|
||||||
int width = 0, int height = 0,
|
int width = 0, int height = 0,
|
||||||
|
@@ -47,7 +47,7 @@ private:
|
|||||||
class WXDLLIMPEXP_GL wxGLCanvas : public wxGLCanvasBase
|
class WXDLLIMPEXP_GL wxGLCanvas : public wxGLCanvasBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT // avoid implicitly converting a wxWindow* to wxGLCanvas
|
explicit // avoid implicitly converting a wxWindow* to wxGLCanvas
|
||||||
wxGLCanvas(wxWindow *parent,
|
wxGLCanvas(wxWindow *parent,
|
||||||
const wxGLAttributes& dispAttrs,
|
const wxGLAttributes& dispAttrs,
|
||||||
wxWindowID id = wxID_ANY,
|
wxWindowID id = wxID_ANY,
|
||||||
@@ -57,7 +57,7 @@ public:
|
|||||||
const wxString& name = wxGLCanvasName,
|
const wxString& name = wxGLCanvasName,
|
||||||
const wxPalette& palette = wxNullPalette);
|
const wxPalette& palette = wxNullPalette);
|
||||||
|
|
||||||
wxEXPLICIT
|
explicit
|
||||||
wxGLCanvas(wxWindow *parent,
|
wxGLCanvas(wxWindow *parent,
|
||||||
wxWindowID id = wxID_ANY,
|
wxWindowID id = wxID_ANY,
|
||||||
const int *attribList = NULL,
|
const int *attribList = NULL,
|
||||||
|
@@ -285,7 +285,7 @@ private:
|
|||||||
class WXDLLIMPEXP_CORE wxVariantDataSafeArray : public wxVariantData
|
class WXDLLIMPEXP_CORE wxVariantDataSafeArray : public wxVariantData
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxVariantDataSafeArray(SAFEARRAY* value = NULL)
|
explicit wxVariantDataSafeArray(SAFEARRAY* value = NULL)
|
||||||
{
|
{
|
||||||
m_value = value;
|
m_value = value;
|
||||||
}
|
}
|
||||||
|
@@ -157,7 +157,7 @@ template <wxUIntPtr INVALID_VALUE = (wxUIntPtr)INVALID_HANDLE_VALUE>
|
|||||||
class AutoHANDLE
|
class AutoHANDLE
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT AutoHANDLE(HANDLE handle = InvalidHandle()) : m_handle(handle) { }
|
explicit AutoHANDLE(HANDLE handle = InvalidHandle()) : m_handle(handle) { }
|
||||||
|
|
||||||
bool IsOk() const { return m_handle != InvalidHandle(); }
|
bool IsOk() const { return m_handle != InvalidHandle(); }
|
||||||
operator HANDLE() const { return m_handle; }
|
operator HANDLE() const { return m_handle; }
|
||||||
|
@@ -25,7 +25,7 @@ public:
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
wxEXPLICIT wxCOMPtr(T* ptr)
|
explicit wxCOMPtr(T* ptr)
|
||||||
: m_ptr(ptr)
|
: m_ptr(ptr)
|
||||||
{
|
{
|
||||||
if ( m_ptr )
|
if ( m_ptr )
|
||||||
|
@@ -13,7 +13,7 @@
|
|||||||
class wxPipeInputStream : public wxInputStream
|
class wxPipeInputStream : public wxInputStream
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxPipeInputStream(HANDLE hInput);
|
explicit wxPipeInputStream(HANDLE hInput);
|
||||||
virtual ~wxPipeInputStream();
|
virtual ~wxPipeInputStream();
|
||||||
|
|
||||||
// returns true if the pipe is still opened
|
// returns true if the pipe is still opened
|
||||||
@@ -34,7 +34,7 @@ protected:
|
|||||||
class wxPipeOutputStream: public wxOutputStream
|
class wxPipeOutputStream: public wxOutputStream
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxPipeOutputStream(HANDLE hOutput);
|
explicit wxPipeOutputStream(HANDLE hOutput);
|
||||||
virtual ~wxPipeOutputStream() { Close(); }
|
virtual ~wxPipeOutputStream() { Close(); }
|
||||||
bool Close();
|
bool Close();
|
||||||
|
|
||||||
|
@@ -19,13 +19,13 @@
|
|||||||
class wxTextMeasure : public wxTextMeasureBase
|
class wxTextMeasure : public wxTextMeasureBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxTextMeasure(const wxDC *dc, const wxFont *font = NULL)
|
explicit wxTextMeasure(const wxDC *dc, const wxFont *font = NULL)
|
||||||
: wxTextMeasureBase(dc, font)
|
: wxTextMeasureBase(dc, font)
|
||||||
{
|
{
|
||||||
Init();
|
Init();
|
||||||
}
|
}
|
||||||
|
|
||||||
wxEXPLICIT wxTextMeasure(const wxWindow *win, const wxFont *font = NULL)
|
explicit wxTextMeasure(const wxWindow *win, const wxFont *font = NULL)
|
||||||
: wxTextMeasureBase(win, font)
|
: wxTextMeasureBase(win, font)
|
||||||
{
|
{
|
||||||
Init();
|
Init();
|
||||||
|
@@ -268,7 +268,7 @@ class wxObjectDataPtr
|
|||||||
public:
|
public:
|
||||||
typedef T element_type;
|
typedef T element_type;
|
||||||
|
|
||||||
wxEXPLICIT wxObjectDataPtr(T *ptr = NULL) : m_ptr(ptr) {}
|
explicit wxObjectDataPtr(T *ptr = NULL) : m_ptr(ptr) {}
|
||||||
|
|
||||||
// copy ctor
|
// copy ctor
|
||||||
wxObjectDataPtr(const wxObjectDataPtr<T> &tocopy)
|
wxObjectDataPtr(const wxObjectDataPtr<T> &tocopy)
|
||||||
|
@@ -24,9 +24,9 @@ public:
|
|||||||
// class is supposed to create the buttons and layout everything.
|
// class is supposed to create the buttons and layout everything.
|
||||||
//
|
//
|
||||||
// Takes ownership of the adaptor pointer.
|
// Takes ownership of the adaptor pointer.
|
||||||
wxEXPLICIT wxAddRemoveImplBase(wxAddRemoveAdaptor* adaptor,
|
explicit wxAddRemoveImplBase(wxAddRemoveAdaptor* adaptor,
|
||||||
wxAddRemoveCtrl* WXUNUSED(parent),
|
wxAddRemoveCtrl* WXUNUSED(parent),
|
||||||
wxWindow* ctrlItems)
|
wxWindow* ctrlItems)
|
||||||
: m_adaptor(adaptor)
|
: m_adaptor(adaptor)
|
||||||
{
|
{
|
||||||
ctrlItems->Bind(wxEVT_CHAR, &wxAddRemoveImplBase::OnChar, this);
|
ctrlItems->Bind(wxEVT_CHAR, &wxAddRemoveImplBase::OnChar, this);
|
||||||
@@ -105,9 +105,9 @@ private:
|
|||||||
class wxAddRemoveImplWithButtons : public wxAddRemoveImplBase
|
class wxAddRemoveImplWithButtons : public wxAddRemoveImplBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxAddRemoveImplWithButtons(wxAddRemoveAdaptor* adaptor,
|
explicit wxAddRemoveImplWithButtons(wxAddRemoveAdaptor* adaptor,
|
||||||
wxAddRemoveCtrl* parent,
|
wxAddRemoveCtrl* parent,
|
||||||
wxWindow* ctrlItems)
|
wxWindow* ctrlItems)
|
||||||
: wxAddRemoveImplBase(adaptor, parent, ctrlItems)
|
: wxAddRemoveImplBase(adaptor, parent, ctrlItems)
|
||||||
{
|
{
|
||||||
m_btnAdd =
|
m_btnAdd =
|
||||||
|
@@ -19,7 +19,7 @@
|
|||||||
class wxFDIOEventLoopSourceHandler : public wxFDIOHandler
|
class wxFDIOEventLoopSourceHandler : public wxFDIOHandler
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxFDIOEventLoopSourceHandler(wxEventLoopSourceHandler* handler)
|
explicit wxFDIOEventLoopSourceHandler(wxEventLoopSourceHandler* handler)
|
||||||
: m_handler(handler)
|
: m_handler(handler)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@@ -32,7 +32,7 @@ public:
|
|||||||
|
|
||||||
// Convert from wxIcon / wxCursor
|
// Convert from wxIcon / wxCursor
|
||||||
wxBitmap(const wxIcon& icon) { CopyFromIcon(icon); }
|
wxBitmap(const wxIcon& icon) { CopyFromIcon(icon); }
|
||||||
wxEXPLICIT wxBitmap(const wxCursor& cursor);
|
explicit wxBitmap(const wxCursor& cursor);
|
||||||
|
|
||||||
static void InitStandardHandlers();
|
static void InitStandardHandlers();
|
||||||
|
|
||||||
|
@@ -31,7 +31,7 @@ private:
|
|||||||
class WXDLLIMPEXP_GL wxGLCanvas : public wxGLCanvasBase
|
class WXDLLIMPEXP_GL wxGLCanvas : public wxGLCanvasBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT // avoid implicitly converting a wxWindow* to wxGLCanvas
|
explicit // avoid implicitly converting a wxWindow* to wxGLCanvas
|
||||||
wxGLCanvas(wxWindow *parent,
|
wxGLCanvas(wxWindow *parent,
|
||||||
wxWindowID id = wxID_ANY,
|
wxWindowID id = wxID_ANY,
|
||||||
const int *attribList = NULL,
|
const int *attribList = NULL,
|
||||||
|
@@ -24,8 +24,8 @@ class wxScopedArray
|
|||||||
public:
|
public:
|
||||||
typedef T element_type;
|
typedef T element_type;
|
||||||
|
|
||||||
wxEXPLICIT wxScopedArray(T * array = NULL) : m_array(array) { }
|
explicit wxScopedArray(T * array = NULL) : m_array(array) { }
|
||||||
wxEXPLICIT wxScopedArray(size_t count) : m_array(new T[count]) { }
|
explicit wxScopedArray(size_t count) : m_array(new T[count]) { }
|
||||||
|
|
||||||
~wxScopedArray() { delete [] m_array; }
|
~wxScopedArray() { delete [] m_array; }
|
||||||
|
|
||||||
@@ -77,7 +77,7 @@ private: \
|
|||||||
name & operator=(name const &); \
|
name & operator=(name const &); \
|
||||||
\
|
\
|
||||||
public: \
|
public: \
|
||||||
wxEXPLICIT name(T * p = NULL) : m_ptr(p) \
|
explicit name(T * p = NULL) : m_ptr(p) \
|
||||||
{} \
|
{} \
|
||||||
\
|
\
|
||||||
~name(); \
|
~name(); \
|
||||||
|
@@ -40,7 +40,7 @@ class wxScopedPtr
|
|||||||
public:
|
public:
|
||||||
typedef T element_type;
|
typedef T element_type;
|
||||||
|
|
||||||
wxEXPLICIT wxScopedPtr(T * ptr = NULL) : m_ptr(ptr) { }
|
explicit wxScopedPtr(T * ptr = NULL) : m_ptr(ptr) { }
|
||||||
|
|
||||||
~wxScopedPtr() { wxCHECKED_DELETE(m_ptr); }
|
~wxScopedPtr() { wxCHECKED_DELETE(m_ptr); }
|
||||||
|
|
||||||
@@ -123,7 +123,7 @@ private: \
|
|||||||
name & operator=(name const &); \
|
name & operator=(name const &); \
|
||||||
\
|
\
|
||||||
public: \
|
public: \
|
||||||
wxEXPLICIT name(T * ptr = NULL) \
|
explicit name(T * ptr = NULL) \
|
||||||
: m_ptr(ptr) { } \
|
: m_ptr(ptr) { } \
|
||||||
\
|
\
|
||||||
~name(); \
|
~name(); \
|
||||||
|
@@ -64,7 +64,7 @@ enum wxScrollbarVisibility
|
|||||||
class WXDLLIMPEXP_CORE wxAnyScrollHelperBase
|
class WXDLLIMPEXP_CORE wxAnyScrollHelperBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxAnyScrollHelperBase(wxWindow* win);
|
explicit wxAnyScrollHelperBase(wxWindow* win);
|
||||||
virtual ~wxAnyScrollHelperBase() {}
|
virtual ~wxAnyScrollHelperBase() {}
|
||||||
|
|
||||||
// Disable use of keyboard keys for scrolling. By default cursor movement
|
// Disable use of keyboard keys for scrolling. By default cursor movement
|
||||||
|
@@ -23,7 +23,7 @@ class wxSharedPtr
|
|||||||
public:
|
public:
|
||||||
typedef T element_type;
|
typedef T element_type;
|
||||||
|
|
||||||
wxEXPLICIT wxSharedPtr( T* ptr = NULL )
|
explicit wxSharedPtr( T* ptr = NULL )
|
||||||
: m_ref(NULL)
|
: m_ref(NULL)
|
||||||
{
|
{
|
||||||
if (ptr)
|
if (ptr)
|
||||||
@@ -31,7 +31,7 @@ public:
|
|||||||
}
|
}
|
||||||
|
|
||||||
template<typename Deleter>
|
template<typename Deleter>
|
||||||
wxEXPLICIT wxSharedPtr(T* ptr, Deleter d)
|
explicit wxSharedPtr(T* ptr, Deleter d)
|
||||||
: m_ref(NULL)
|
: m_ref(NULL)
|
||||||
{
|
{
|
||||||
if (ptr)
|
if (ptr)
|
||||||
|
@@ -15,7 +15,7 @@
|
|||||||
class wxPipeInputStream : public wxFileInputStream
|
class wxPipeInputStream : public wxFileInputStream
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxPipeInputStream(int fd) : wxFileInputStream(fd) { }
|
explicit wxPipeInputStream(int fd) : wxFileInputStream(fd) { }
|
||||||
|
|
||||||
// return true if the pipe is still opened
|
// return true if the pipe is still opened
|
||||||
bool IsOpened() const { return !Eof(); }
|
bool IsOpened() const { return !Eof(); }
|
||||||
|
@@ -145,7 +145,7 @@ public:
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
reverse_iterator() : m_ptr(NULL) { }
|
reverse_iterator() : m_ptr(NULL) { }
|
||||||
wxEXPLICIT reverse_iterator(iterator it) : m_ptr(it) { }
|
explicit reverse_iterator(iterator it) : m_ptr(it) { }
|
||||||
reverse_iterator(const reverse_iterator& it) : m_ptr(it.m_ptr) { }
|
reverse_iterator(const reverse_iterator& it) : m_ptr(it.m_ptr) { }
|
||||||
|
|
||||||
reference operator*() const { return *m_ptr; }
|
reference operator*() const { return *m_ptr; }
|
||||||
@@ -189,7 +189,7 @@ public:
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
const_reverse_iterator() : m_ptr(NULL) { }
|
const_reverse_iterator() : m_ptr(NULL) { }
|
||||||
wxEXPLICIT const_reverse_iterator(const_iterator it) : m_ptr(it) { }
|
explicit const_reverse_iterator(const_iterator it) : m_ptr(it) { }
|
||||||
const_reverse_iterator(const reverse_iterator& it) : m_ptr(it.m_ptr) { }
|
const_reverse_iterator(const reverse_iterator& it) : m_ptr(it.m_ptr) { }
|
||||||
const_reverse_iterator(const const_reverse_iterator& it) : m_ptr(it.m_ptr) { }
|
const_reverse_iterator(const const_reverse_iterator& it) : m_ptr(it.m_ptr) { }
|
||||||
|
|
||||||
|
@@ -581,7 +581,7 @@ public:
|
|||||||
public:
|
public:
|
||||||
// Notice that window can be NULL here, for convenience. In this case
|
// Notice that window can be NULL here, for convenience. In this case
|
||||||
// this class simply doesn't do anything.
|
// this class simply doesn't do anything.
|
||||||
wxEXPLICIT ChildrenRepositioningGuard(wxWindowBase* win)
|
explicit ChildrenRepositioningGuard(wxWindowBase* win)
|
||||||
: m_win(win),
|
: m_win(win),
|
||||||
m_callEnd(win && win->BeginRepositioningChildren())
|
m_callEnd(win && win->BeginRepositioningChildren())
|
||||||
{
|
{
|
||||||
|
@@ -35,7 +35,7 @@ class wxWindowPtr : public wxSharedPtr<T>
|
|||||||
public:
|
public:
|
||||||
typedef T element_type;
|
typedef T element_type;
|
||||||
|
|
||||||
wxEXPLICIT wxWindowPtr(element_type* win)
|
explicit wxWindowPtr(element_type* win)
|
||||||
: wxSharedPtr<T>(win, wxPrivate::wxWindowDeleter())
|
: wxSharedPtr<T>(win, wxPrivate::wxWindowDeleter())
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@@ -26,7 +26,7 @@ public:
|
|||||||
const wxString& name = wxGLCanvasName,
|
const wxString& name = wxGLCanvasName,
|
||||||
const wxPalette& palette = wxNullPalette);
|
const wxPalette& palette = wxNullPalette);
|
||||||
|
|
||||||
wxEXPLICIT // avoid implicitly converting a wxWindow* to wxGLCanvas
|
explicit // avoid implicitly converting a wxWindow* to wxGLCanvas
|
||||||
wxGLCanvas(wxWindow *parent,
|
wxGLCanvas(wxWindow *parent,
|
||||||
wxWindowID id = wxID_ANY,
|
wxWindowID id = wxID_ANY,
|
||||||
const int *attribList = NULL,
|
const int *attribList = NULL,
|
||||||
|
@@ -1699,17 +1699,6 @@ template <typename T> wxDELETEA(T*& array);
|
|||||||
*/
|
*/
|
||||||
#define wxDEPRECATED_BUT_USED_INTERNALLY_INLINE(func, body)
|
#define wxDEPRECATED_BUT_USED_INTERNALLY_INLINE(func, body)
|
||||||
|
|
||||||
/**
|
|
||||||
@c wxEXPLICIT is a macro which expands to the C++ @c explicit keyword if
|
|
||||||
the compiler supports it or nothing otherwise. Thus, it can be used even in
|
|
||||||
the code which might have to be compiled with an old compiler without
|
|
||||||
support for this language feature but still take advantage of it when it is
|
|
||||||
available.
|
|
||||||
|
|
||||||
@header{wx/defs.h}
|
|
||||||
*/
|
|
||||||
#define wxEXPLICIT
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@c wxOVERRIDE expands to the C++11 @c override keyword if it's supported by
|
@c wxOVERRIDE expands to the C++11 @c override keyword if it's supported by
|
||||||
the compiler or nothing otherwise.
|
the compiler or nothing otherwise.
|
||||||
|
@@ -26,7 +26,7 @@ public:
|
|||||||
Creates shared pointer from the raw pointer @a ptr and takes ownership
|
Creates shared pointer from the raw pointer @a ptr and takes ownership
|
||||||
of it.
|
of it.
|
||||||
*/
|
*/
|
||||||
wxEXPLICIT wxSharedPtr(T* ptr = NULL);
|
explicit wxSharedPtr(T* ptr = NULL);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Constructor.
|
Constructor.
|
||||||
@@ -42,7 +42,7 @@ public:
|
|||||||
@since 3.0
|
@since 3.0
|
||||||
*/
|
*/
|
||||||
template<typename Deleter>
|
template<typename Deleter>
|
||||||
wxEXPLICIT wxSharedPtr(T* ptr, Deleter d);
|
explicit wxSharedPtr(T* ptr, Deleter d);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
Copy constructor.
|
Copy constructor.
|
||||||
|
@@ -1368,7 +1368,7 @@ void MyFrame::AddRemove(wxCommandEvent& WXUNUSED(event))
|
|||||||
class ListBoxAdaptor : public wxAddRemoveAdaptor
|
class ListBoxAdaptor : public wxAddRemoveAdaptor
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT ListBoxAdaptor(wxListBox* lbox)
|
explicit ListBoxAdaptor(wxListBox* lbox)
|
||||||
: m_lbox(lbox)
|
: m_lbox(lbox)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@@ -82,7 +82,7 @@ wxDEFINE_SCOPED_PTR(wxAppConsole, wxAppPtrBase)
|
|||||||
class wxAppPtr : public wxAppPtrBase
|
class wxAppPtr : public wxAppPtrBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxAppPtr(wxAppConsole *ptr = NULL) : wxAppPtrBase(ptr) { }
|
explicit wxAppPtr(wxAppConsole *ptr = NULL) : wxAppPtrBase(ptr) { }
|
||||||
~wxAppPtr()
|
~wxAppPtr()
|
||||||
{
|
{
|
||||||
if ( get() )
|
if ( get() )
|
||||||
|
@@ -2022,7 +2022,7 @@ namespace
|
|||||||
class ValidationTraverserBase
|
class ValidationTraverserBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT ValidationTraverserBase(wxWindowBase* win)
|
explicit ValidationTraverserBase(wxWindowBase* win)
|
||||||
: m_win(static_cast<wxWindow*>(win))
|
: m_win(static_cast<wxWindow*>(win))
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@@ -2084,7 +2084,7 @@ bool wxWindowBase::Validate()
|
|||||||
class ValidateTraverser : public ValidationTraverserBase
|
class ValidateTraverser : public ValidationTraverserBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT ValidateTraverser(wxWindowBase* win)
|
explicit ValidateTraverser(wxWindowBase* win)
|
||||||
: ValidationTraverserBase(win)
|
: ValidationTraverserBase(win)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@@ -2112,7 +2112,7 @@ bool wxWindowBase::TransferDataToWindow()
|
|||||||
class DataToWindowTraverser : public ValidationTraverserBase
|
class DataToWindowTraverser : public ValidationTraverserBase
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT DataToWindowTraverser(wxWindowBase* win)
|
explicit DataToWindowTraverser(wxWindowBase* win)
|
||||||
: ValidationTraverserBase(win)
|
: ValidationTraverserBase(win)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@@ -83,7 +83,7 @@ gtk_changed(GtkSpinButton* spinbutton, wxSpinCtrl* win)
|
|||||||
class wxSpinCtrlEventDisabler
|
class wxSpinCtrlEventDisabler
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT wxSpinCtrlEventDisabler(wxSpinCtrlGTKBase* spin)
|
explicit wxSpinCtrlEventDisabler(wxSpinCtrlGTKBase* spin)
|
||||||
: m_spin(spin)
|
: m_spin(spin)
|
||||||
{
|
{
|
||||||
m_spin->GtkDisableEvents();
|
m_spin->GtkDisableEvents();
|
||||||
|
@@ -490,7 +490,7 @@ void wxRibbonBar::SetTabCtrlMargins(int left, int right)
|
|||||||
|
|
||||||
struct PageComparedBySmallWidthAsc
|
struct PageComparedBySmallWidthAsc
|
||||||
{
|
{
|
||||||
wxEXPLICIT PageComparedBySmallWidthAsc(wxRibbonPageTabInfo* page)
|
explicit PageComparedBySmallWidthAsc(wxRibbonPageTabInfo* page)
|
||||||
: m_page(page)
|
: m_page(page)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
@@ -302,7 +302,7 @@ void ExecTestCase::TestProcess()
|
|||||||
class TestAsyncProcess : public wxProcess
|
class TestAsyncProcess : public wxProcess
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
wxEXPLICIT TestAsyncProcess()
|
explicit TestAsyncProcess()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user