add wxSize overloads to wxBitmap ctors and to wxBitmap::Create
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@59526 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -608,13 +608,13 @@ PicHandle wxBitmapRefData::GetPictHandle()
|
||||
err = GraphicsExportDoExport(exporter, NULL);
|
||||
CGImageRelease( imageRef );
|
||||
|
||||
size_t handleSize = GetHandleSize( (Handle) m_pictHandle );
|
||||
// the 512 bytes header is only needed for pict files, but not in memory
|
||||
if ( handleSize >= 512 )
|
||||
{
|
||||
memmove( *m_pictHandle , (char*)(*m_pictHandle)+512, handleSize - 512 );
|
||||
SetHandleSize( (Handle) m_pictHandle, handleSize - 512 );
|
||||
}
|
||||
size_t handleSize = GetHandleSize( (Handle) m_pictHandle );
|
||||
// the 512 bytes header is only needed for pict files, but not in memory
|
||||
if ( handleSize >= 512 )
|
||||
{
|
||||
memmove( *m_pictHandle , (char*)(*m_pictHandle)+512, handleSize - 512 );
|
||||
SetHandleSize( (Handle) m_pictHandle, handleSize - 512 );
|
||||
}
|
||||
}
|
||||
CloseComponent( exporter );
|
||||
}
|
||||
@@ -785,6 +785,12 @@ wxBitmapRefData::~wxBitmapRefData()
|
||||
Free() ;
|
||||
}
|
||||
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// wxBitmap
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
bool wxBitmap::CopyFromIcon(const wxIcon& icon)
|
||||
{
|
||||
bool created = false ;
|
||||
@@ -890,14 +896,6 @@ bool wxBitmap::CopyFromIcon(const wxIcon& icon)
|
||||
return true;
|
||||
}
|
||||
|
||||
wxBitmap::wxBitmap()
|
||||
{
|
||||
}
|
||||
|
||||
wxBitmap::~wxBitmap()
|
||||
{
|
||||
}
|
||||
|
||||
wxBitmap::wxBitmap(const char bits[], int the_width, int the_height, int no_bits)
|
||||
{
|
||||
wxBitmapRefData* bitmapRefData;
|
||||
@@ -952,11 +950,6 @@ wxBitmap::wxBitmap(const char bits[], int the_width, int the_height, int no_bits
|
||||
} /* bitmapRefData->IsOk() */
|
||||
}
|
||||
|
||||
wxBitmap::wxBitmap(int w, int h, int d)
|
||||
{
|
||||
(void)Create(w, h, d);
|
||||
}
|
||||
|
||||
wxBitmap::wxBitmap(const void* data, wxBitmapType type, int width, int height, int depth)
|
||||
{
|
||||
(void) Create(data, type, width, height, depth);
|
||||
|
||||
Reference in New Issue
Block a user