Make wxBitmap::ConvertToDisabled() available in all ports.

This method was defined in wxBitmapBase which is not used by wxMSW (and wxOS2)
so it wasn't available there. Move the definition of the method inline and
reuse it for all ports, making it part of either wxBitmapBase or wxBitmap as
appropriate.

This is clearly ugly but we still have no good solution for deriving wxBitmap
from wxBitmapBase in wxMSW as it already inherits from MSW-specific wxGDIImage
there.

Also document that ConvertToDisabled() is only available when wxUSE_IMAGE==1.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@66086 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2010-11-10 13:51:51 +00:00
parent 82302ad45a
commit ac04aa9943
6 changed files with 24 additions and 16 deletions

View File

@@ -25,7 +25,6 @@ class WXDLLIMPEXP_FWD_CORE wxIcon;
class WXDLLIMPEXP_FWD_CORE wxMask;
class WXDLLIMPEXP_FWD_CORE wxCursor;
class WXDLLIMPEXP_FWD_CORE wxControl;
class WXDLLIMPEXP_FWD_CORE wxImage;
class WXDLLIMPEXP_FWD_CORE wxPixelDataBase;
// ----------------------------------------------------------------------------
@@ -149,6 +148,7 @@ public:
virtual ~wxBitmap();
wxImage ConvertToImage() const;
wxBitmap ConvertToDisabled(unsigned char brightness = 255) const;
// get the given part of bitmap
wxBitmap GetSubBitmap(const wxRect& rRect) const;