added check for supported depth and 'not implemented' wxFAIL_MSG
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41213 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -212,6 +212,7 @@ bool wxBitmap::Create(int width, int height, int depth)
|
|||||||
UnRef();
|
UnRef();
|
||||||
|
|
||||||
wxCHECK_MSG( width > 0 && height > 0, false, wxT("invalid bitmap size") );
|
wxCHECK_MSG( width > 0 && height > 0, false, wxT("invalid bitmap size") );
|
||||||
|
wxCHECK_MSG( depth == -1, false, wxT("only default depth supported now") );
|
||||||
|
|
||||||
DFBSurfaceDescription desc;
|
DFBSurfaceDescription desc;
|
||||||
desc.flags = (DFBSurfaceDescriptionFlags)(
|
desc.flags = (DFBSurfaceDescriptionFlags)(
|
||||||
@@ -264,6 +265,8 @@ wxBitmap::wxBitmap(const wxString &filename, wxBitmapType type)
|
|||||||
wxBitmap::wxBitmap(const char bits[], int width, int height, int depth)
|
wxBitmap::wxBitmap(const char bits[], int width, int height, int depth)
|
||||||
{
|
{
|
||||||
wxCHECK_RET( depth == 1, wxT("can only create mono bitmap from XBM data") );
|
wxCHECK_RET( depth == 1, wxT("can only create mono bitmap from XBM data") );
|
||||||
|
|
||||||
|
wxFAIL_MSG( _T("not implemented") );
|
||||||
}
|
}
|
||||||
|
|
||||||
bool wxBitmap::Ok() const
|
bool wxBitmap::Ok() const
|
||||||
|
Reference in New Issue
Block a user