mirror of
https://github.com/cookiengineer/audacity
synced 2025-04-30 15:49:41 +02:00
Allow small color differences
Makes the theme respond better to system colors Signed-off-by: akleja <storspov@gmail.com>
This commit is contained in:
parent
c3c5765a92
commit
cc7c659d6e
@ -353,18 +353,12 @@ void ThemeBase::RecolourTheme()
|
||||
#else
|
||||
wxColour To = wxSystemSettings::GetColour( wxSYS_COLOUR_3DFACE );
|
||||
#endif
|
||||
// only recolour if recolouring is slight.
|
||||
int d = ColourDistance( From, To );
|
||||
|
||||
// Don't recolour if difference is too big.
|
||||
int d = ColourDistance( From, To );
|
||||
if( d > 120 )
|
||||
return;
|
||||
|
||||
// A minor tint difference from standard does not need
|
||||
// to be recouloured either. Includes case of d==0 which is nothing
|
||||
// needs to be done.
|
||||
if( d < 40 )
|
||||
return;
|
||||
|
||||
Colour( clrMedium ) = To;
|
||||
RecolourBitmap( bmpUpButtonLarge, From, To );
|
||||
|
Loading…
x
Reference in New Issue
Block a user