Merge branch 'no-global-ops'
Don't define operators for wx types in global scope. This results in much better error messages when the compiler gives an error about failing to resolve a call to some operator in user code because it doesn't list all the wx-defined operators as candidates. In practice, this cuts down error messages from 500 (!) lines to 2 with gcc. See #24190.
This commit is contained in:
commit
a2f7a933e8
28 changed files with 1074 additions and 1002 deletions
|
|
@ -18,6 +18,7 @@
|
|||
#include "wx/gdicmn.h" // for wxBitmapType
|
||||
#include "wx/colour.h"
|
||||
#include "wx/image.h"
|
||||
#include "wx/variant.h"
|
||||
|
||||
class WXDLLIMPEXP_FWD_CORE wxBitmap;
|
||||
class WXDLLIMPEXP_FWD_CORE wxBitmapHandler;
|
||||
|
|
@ -28,15 +29,6 @@ class WXDLLIMPEXP_FWD_CORE wxMask;
|
|||
class WXDLLIMPEXP_FWD_CORE wxPalette;
|
||||
class WXDLLIMPEXP_FWD_CORE wxPixelDataBase;
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxVariant support
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
#if wxUSE_VARIANT
|
||||
#include "wx/variant.h"
|
||||
DECLARE_VARIANT_OBJECT_EXPORTED(wxBitmap,WXDLLIMPEXP_CORE)
|
||||
#endif
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxMask represents the transparent area of the bitmap
|
||||
// ----------------------------------------------------------------------------
|
||||
|
|
@ -100,6 +92,9 @@ public:
|
|||
|
||||
// Rescale the given bitmap to the requested size.
|
||||
static void Rescale(wxBitmap& bmp, const wxSize& sizeNeeded);
|
||||
|
||||
// wxVariant support
|
||||
wxDECLARE_VARIANT_OBJECT_EXPORTED(wxBitmap, WXDLLIMPEXP_CORE);
|
||||
};
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue