wxMemoryDCImpl::~wxMemoryDCImpl()
{
- if ( m_selected.Ok() )
+ if ( m_selected.IsOk() )
{
m_selected.EndRawAccess() ;
- delete m_graphicContext ;
- m_graphicContext = NULL ;
+ wxDELETE(m_graphicContext);
}
}
void wxMemoryDCImpl::DoSelect( const wxBitmap& bitmap )
{
- if ( m_selected.Ok() )
+ if ( m_selected.IsOk() )
{
m_selected.EndRawAccess() ;
- delete m_graphicContext ;
- m_graphicContext = NULL ;
+ wxDELETE(m_graphicContext);
}
m_selected = bitmap;
- if (m_selected.Ok())
+ if (m_selected.IsOk())
{
if ( m_selected.GetDepth() != 1 )
m_selected.UseAlpha() ;
void wxMemoryDCImpl::DoGetSize( int *width, int *height ) const
{
- if (m_selected.Ok())
+ if (m_selected.IsOk())
{
if (width)
(*width) = m_selected.GetWidth();