mirror of
https://github.com/cookiengineer/audacity
synced 2025-07-16 08:37:42 +02:00
Option so (theme) developers can work with Mac buttons on PC (and vice versa)
This commit is contained in:
parent
de798b17d5
commit
2cc39d791f
@ -177,6 +177,13 @@ void GUIPrefs::PopulateOrExchange(ShuttleGui & S)
|
|||||||
S.TieCheckBox(_("Show e&xtra menus"),
|
S.TieCheckBox(_("Show e&xtra menus"),
|
||||||
wxT("/GUI/ShowExtraMenus"),
|
wxT("/GUI/ShowExtraMenus"),
|
||||||
false);
|
false);
|
||||||
|
#ifdef EXPERIMENTAL_THEME_PREFS
|
||||||
|
// We do not want to make this option mainstream. It's a
|
||||||
|
// convenience for developers.
|
||||||
|
S.TieCheckBox(_("Show alternative &styling (Mac vs PC)"),
|
||||||
|
wxT("/GUI/ShowMac"),
|
||||||
|
false);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
S.EndStatic();
|
S.EndStatic();
|
||||||
|
|
||||||
|
@ -52,6 +52,7 @@ in which buttons can be placed.
|
|||||||
#include "../commands/Keyboard.h"
|
#include "../commands/Keyboard.h"
|
||||||
#include "../widgets/AButton.h"
|
#include "../widgets/AButton.h"
|
||||||
#include "../widgets/Grabber.h"
|
#include "../widgets/Grabber.h"
|
||||||
|
#include "../Prefs.h"
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////
|
||||||
/// ToolBarResizer
|
/// ToolBarResizer
|
||||||
@ -705,28 +706,50 @@ void ToolBar::MakeRecoloredImage( teBmps eBmpOut, teBmps eBmpIn )
|
|||||||
|
|
||||||
void ToolBar:: MakeButtonBackgroundsLarge()
|
void ToolBar:: MakeButtonBackgroundsLarge()
|
||||||
{
|
{
|
||||||
#ifdef USE_AQUA_THEME
|
|
||||||
MakeMacRecoloredImage( bmpRecoloredUpLarge, bmpMacUpButton );
|
bool bUseAqua = false;
|
||||||
MakeMacRecoloredImage( bmpRecoloredDownLarge, bmpMacDownButton );
|
|
||||||
MakeMacRecoloredImage( bmpRecoloredHiliteLarge, bmpMacHiliteButton );
|
#ifdef EXPERIMENTAL_THEME_PREFS
|
||||||
#else
|
gPrefs->Read( wxT("/GUI/ShowMac"), &bUseAqua, false);
|
||||||
MakeRecoloredImage( bmpRecoloredUpLarge, bmpUpButtonLarge );
|
|
||||||
MakeRecoloredImage( bmpRecoloredDownLarge, bmpDownButtonLarge );
|
|
||||||
MakeRecoloredImage( bmpRecoloredHiliteLarge, bmpHiliteButtonLarge );
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef USE_AQUA_THEME
|
||||||
|
bUseAqua = !bUseAqua;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if( bUseAqua ){
|
||||||
|
MakeMacRecoloredImage( bmpRecoloredUpLarge, bmpMacUpButton );
|
||||||
|
MakeMacRecoloredImage( bmpRecoloredDownLarge, bmpMacDownButton );
|
||||||
|
MakeMacRecoloredImage( bmpRecoloredHiliteLarge, bmpMacHiliteButton );
|
||||||
|
} else {
|
||||||
|
MakeRecoloredImage( bmpRecoloredUpLarge, bmpUpButtonLarge );
|
||||||
|
MakeRecoloredImage( bmpRecoloredDownLarge, bmpDownButtonLarge );
|
||||||
|
MakeRecoloredImage( bmpRecoloredHiliteLarge, bmpHiliteButtonLarge );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ToolBar::MakeButtonBackgroundsSmall()
|
void ToolBar::MakeButtonBackgroundsSmall()
|
||||||
{
|
{
|
||||||
#ifdef USE_AQUA_THEME
|
|
||||||
MakeMacRecoloredImage( bmpRecoloredUpSmall, bmpMacUpButtonSmall );
|
bool bUseAqua = false;
|
||||||
MakeMacRecoloredImage( bmpRecoloredDownSmall, bmpMacDownButtonSmall );
|
|
||||||
MakeMacRecoloredImage( bmpRecoloredHiliteSmall, bmpMacHiliteButtonSmall );
|
#ifdef EXPERIMENTAL_THEME_PREFS
|
||||||
#else
|
gPrefs->Read( wxT("/GUI/ShowMac"), &bUseAqua, false);
|
||||||
MakeRecoloredImage( bmpRecoloredUpSmall, bmpUpButtonSmall );
|
|
||||||
MakeRecoloredImage( bmpRecoloredDownSmall, bmpDownButtonSmall );
|
|
||||||
MakeRecoloredImage( bmpRecoloredHiliteSmall, bmpHiliteButtonSmall );
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef USE_AQUA_THEME
|
||||||
|
bUseAqua = !bUseAqua;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
if( bUseAqua ){
|
||||||
|
MakeMacRecoloredImage( bmpRecoloredUpSmall, bmpMacUpButtonSmall );
|
||||||
|
MakeMacRecoloredImage( bmpRecoloredDownSmall, bmpMacDownButtonSmall );
|
||||||
|
MakeMacRecoloredImage( bmpRecoloredHiliteSmall, bmpMacHiliteButtonSmall );
|
||||||
|
} else {
|
||||||
|
MakeRecoloredImage( bmpRecoloredUpSmall, bmpUpButtonSmall );
|
||||||
|
MakeRecoloredImage( bmpRecoloredDownSmall, bmpDownButtonSmall );
|
||||||
|
MakeRecoloredImage( bmpRecoloredHiliteSmall, bmpHiliteButtonSmall );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Makes a button and its four different state bitmaps
|
/// Makes a button and its four different state bitmaps
|
||||||
|
Loading…
x
Reference in New Issue
Block a user