Turns out only MSW has odd behavior for bitmap sizing
This commit is contained in:
parent
9c1fac3e21
commit
4e6092a280
|
@ -95,7 +95,7 @@ void BITMAP_BUTTON::SetPadding( int aPadding )
|
||||||
void BITMAP_BUTTON::SetBitmap( const wxBitmapBundle& aBmp )
|
void BITMAP_BUTTON::SetBitmap( const wxBitmapBundle& aBmp )
|
||||||
{
|
{
|
||||||
m_normalBitmap = aBmp;
|
m_normalBitmap = aBmp;
|
||||||
#ifdef __WXMAC__
|
#ifndef __WXMSW__
|
||||||
m_unadjustedMinSize = m_normalBitmap.GetDefaultSize();
|
m_unadjustedMinSize = m_normalBitmap.GetDefaultSize();
|
||||||
#else
|
#else
|
||||||
m_unadjustedMinSize = m_normalBitmap.GetPreferredBitmapSizeFor( this );
|
m_unadjustedMinSize = m_normalBitmap.GetPreferredBitmapSizeFor( this );
|
||||||
|
@ -369,4 +369,4 @@ bool BITMAP_BUTTON::IsChecked() const
|
||||||
wxASSERT_MSG( hasFlag( wxCONTROL_CHECKABLE ), wxS( "Button is not a checkButton." ) );
|
wxASSERT_MSG( hasFlag( wxCONTROL_CHECKABLE ), wxS( "Button is not a checkButton." ) );
|
||||||
|
|
||||||
return hasFlag( wxCONTROL_CHECKED );
|
return hasFlag( wxCONTROL_CHECKED );
|
||||||
}
|
}
|
||||||
|
|
|
@ -97,7 +97,7 @@ void SPLIT_BUTTON::SetBitmap( const wxBitmapBundle& aBmp )
|
||||||
{
|
{
|
||||||
m_bitmap = aBmp;
|
m_bitmap = aBmp;
|
||||||
|
|
||||||
#ifdef __WXMAC__
|
#ifndef __WXMSW__
|
||||||
SetMinSize( m_bitmap.GetDefaultSize() );
|
SetMinSize( m_bitmap.GetDefaultSize() );
|
||||||
#else
|
#else
|
||||||
SetMinSize( m_bitmap.GetPreferredBitmapSizeFor( this ) );
|
SetMinSize( m_bitmap.GetPreferredBitmapSizeFor( this ) );
|
||||||
|
|
|
@ -77,7 +77,7 @@ void STD_BITMAP_BUTTON::SetBitmap( const wxBitmapBundle& aBmp )
|
||||||
{
|
{
|
||||||
m_bitmap = aBmp;
|
m_bitmap = aBmp;
|
||||||
|
|
||||||
#ifdef __WXMAC__
|
#ifndef __WXMSW__
|
||||||
wxSize size = m_bitmap.GetDefaultSize();
|
wxSize size = m_bitmap.GetDefaultSize();
|
||||||
#else
|
#else
|
||||||
wxSize size = m_bitmap.GetPreferredBitmapSizeFor( this );
|
wxSize size = m_bitmap.GetPreferredBitmapSizeFor( this );
|
||||||
|
|
Loading…
Reference in New Issue