Added new ctor for wxBitmap using wxCursor for wxQT (similar to wxGTK)

This is the implementation that should had been included in r78348

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@78353 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Mariano Reingart
2015-01-06 07:12:17 +00:00
parent 984238305b
commit 772d42cad1

View File

@@ -219,6 +219,14 @@ wxBitmap::wxBitmap(const wxImage& image, int depth )
m_refData = new wxBitmapRefData(QPixmap::fromImage(ConvertImage(image), flags));
}
wxBitmap::wxBitmap(const wxCursor& cursor)
{
// note that pixmap could be invalid if is not a pixmap cursor
// also, a wxCursor::GetHandle method could be implemented instead of
// accessing the member variable directly
QPixmap pix = cursor.m_qtCursor.pixmap();
m_refData = new wxBitmapRefData(pix);
}
bool wxBitmap::Create(int width, int height, int depth )
{