Move some things to wxBitmapBase to avoid much duplication.
Use proper const for XPM data, and const void* for arbitary bitmap data. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41689 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -53,7 +53,7 @@ public:
|
||||
wxBitmap() { }
|
||||
wxBitmap( int width, int height, int depth = -1 );
|
||||
wxBitmap( const char bits[], int width, int height, int depth = 1 );
|
||||
wxBitmap( const char* const* bits ) { CreateFromXpm(bits); }
|
||||
wxBitmap( const char* const* bits );
|
||||
wxBitmap( const wxString &filename, wxBitmapType type = wxBITMAP_TYPE_XPM );
|
||||
wxBitmap( const wxImage& image, int depth = -1 ) { (void)CreateFromImage(image, depth); }
|
||||
virtual ~wxBitmap();
|
||||
@@ -114,7 +114,6 @@ public:
|
||||
void UseAlpha();
|
||||
|
||||
protected:
|
||||
bool CreateFromXpm(const char* const* bits);
|
||||
bool CreateFromImage(const wxImage& image, int depth);
|
||||
|
||||
private:
|
||||
@@ -144,17 +143,7 @@ private:
|
||||
|
||||
class WXDLLIMPEXP_CORE wxBitmapHandler: public wxBitmapHandlerBase
|
||||
{
|
||||
public:
|
||||
wxBitmapHandler() { }
|
||||
virtual ~wxBitmapHandler();
|
||||
|
||||
virtual bool Create(wxBitmap *bitmap, void *data, long flags, int width, int height, int depth = 1);
|
||||
virtual bool LoadFile(wxBitmap *bitmap, const wxString& name, long flags,
|
||||
int desiredWidth, int desiredHeight);
|
||||
virtual bool SaveFile(const wxBitmap *bitmap, const wxString& name, int type, const wxPalette *palette = NULL);
|
||||
|
||||
private:
|
||||
DECLARE_DYNAMIC_CLASS(wxBitmapHandler)
|
||||
DECLARE_ABSTRACT_CLASS(wxBitmapHandler)
|
||||
};
|
||||
|
||||
#endif // _WX_GTK_BITMAP_H_
|
||||
|
Reference in New Issue
Block a user