View | Details | Raw Unified | Return to issue 86924
Collapse All | Expand All

(-)openoffice.org.orig/svtools/source/misc/imagemgr.cxx (+23 lines)
Lines 614-619 Link Here
614
	static ImageList* _pBigOfficeImgList = NULL;
614
	static ImageList* _pBigOfficeImgList = NULL;
615
	static ImageList* _pSmallHCOfficeImgList = NULL;
615
	static ImageList* _pSmallHCOfficeImgList = NULL;
616
	static ImageList* _pBigHCOfficeImgList = NULL;
616
	static ImageList* _pBigHCOfficeImgList = NULL;
617
	static ULONG nStyle = Application::GetSettings().GetStyleSettings().GetSymbolsStyle();
618
619
	//If the style has been changed, throw away our cache of the older images
620
	if (nStyle != Application::GetSettings().GetStyleSettings().GetSymbolsStyle())
621
	{
622
		delete _pSmallOfficeImgList, _pSmallOfficeImgList = NULL;
623
		delete _pBigOfficeImgList, _pBigOfficeImgList = NULL;
624
		delete _pSmallHCOfficeImgList, _pSmallHCOfficeImgList = NULL;
625
		delete _pBigHCOfficeImgList, _pBigHCOfficeImgList = NULL;
626
		nStyle = Application::GetSettings().GetStyleSettings().GetSymbolsStyle();
627
	}
617
628
618
    // #i21242# MT: For B&W we need the HC Image and must transform.
629
    // #i21242# MT: For B&W we need the HC Image and must transform.
619
    // bHiContrast is TRUE for all dark backgrounds, but we need HC Images for HC White also,
630
    // bHiContrast is TRUE for all dark backgrounds, but we need HC Images for HC White also,
Lines 682-687 Link Here
682
	static ImageList* _pBigImageList = NULL;
693
	static ImageList* _pBigImageList = NULL;
683
	static ImageList* _pSmallHCImageList = NULL;
694
	static ImageList* _pSmallHCImageList = NULL;
684
	static ImageList* _pBigHCImageList = NULL;
695
	static ImageList* _pBigHCImageList = NULL;
696
	static ULONG nStyle = Application::GetSettings().GetStyleSettings().GetSymbolsStyle();
697
698
	//If the style has been changed, throw away our cache of the older images
699
	if (nStyle != Application::GetSettings().GetStyleSettings().GetSymbolsStyle())
700
	{
701
		delete _pSmallImageList, _pSmallImageList = NULL;
702
		delete _pBigImageList, _pBigImageList = NULL;
703
		delete _pSmallHCImageList, _pSmallHCImageList = NULL;
704
		delete _pBigHCImageList, _pBigHCImageList = NULL;
705
		nStyle = Application::GetSettings().GetStyleSettings().GetSymbolsStyle();
706
	}
707
685
708
686
    if ( bBig )
709
    if ( bBig )
687
    {
710
    {
(-)openoffice.org.orig/sfx2/inc/sfx2/mnuitem.hxx (+1 lines)
Lines 172-177 Link Here
172
{
172
{
173
    PopupMenu*	pMenu;
173
    PopupMenu*	pMenu;
174
	BOOL		m_bWasHiContrastMode;
174
	BOOL		m_bWasHiContrastMode;
175
	ULONG		m_nSymbolsStyle;
175
	BOOL		m_bShowMenuImages;
176
	BOOL		m_bShowMenuImages;
176
177
177
protected:
178
protected:
(-)openoffice.org.orig/sfx2/inc/sfx2/tbxctrl.hxx (+1 lines)
Lines 419-424 Link Here
419
	BOOL					bBigImages;
419
	BOOL					bBigImages;
420
    PopupMenu*              pMenu;
420
    PopupMenu*              pMenu;
421
	BOOL					m_bWasHiContrastMode;
421
	BOOL					m_bWasHiContrastMode;
422
	ULONG					m_nSymbolsStyle;
422
	BOOL					m_bShowMenuImages;
423
	BOOL					m_bShowMenuImages;
423
};
424
};
424
425
(-)openoffice.org.orig/sfx2/source/menu/mnuitem.cxx (-1 / +5 lines)
Lines 512-517 Link Here
512
	const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
512
	const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
513
	BOOL bIsHiContrastMode	= rSettings.GetMenuColor().IsDark();
513
	BOOL bIsHiContrastMode	= rSettings.GetMenuColor().IsDark();
514
	m_bWasHiContrastMode	= bIsHiContrastMode;
514
	m_bWasHiContrastMode	= bIsHiContrastMode;
515
    m_nSymbolsStyle         = rSettings.GetSymbolsStyle();
515
	m_bShowMenuImages		= SvtMenuOptions().IsMenuIconsEnabled();
516
	m_bShowMenuImages		= SvtMenuOptions().IsMenuIconsEnabled();
516
517
517
    Reference<com::sun::star::lang::XMultiServiceFactory> aXMultiServiceFactory(::comphelper::getProcessServiceFactory());
518
    Reference<com::sun::star::lang::XMultiServiceFactory> aXMultiServiceFactory(::comphelper::getProcessServiceFactory());
Lines 538-548 Link Here
538
		BOOL bShowMenuImages = SvtMenuOptions().IsMenuIconsEnabled();
539
		BOOL bShowMenuImages = SvtMenuOptions().IsMenuIconsEnabled();
539
		const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
540
		const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
540
		BOOL bIsHiContrastMode = rSettings.GetMenuColor().IsDark();
541
		BOOL bIsHiContrastMode = rSettings.GetMenuColor().IsDark();
542
		BOOL nSymbolsStyle = rSettings.GetSymbolsStyle();
541
543
542
		if (( bIsHiContrastMode != m_bWasHiContrastMode	) ||
544
		if (( bIsHiContrastMode != m_bWasHiContrastMode	) ||
543
			( bShowMenuImages != m_bShowMenuImages		)	 )
545
			( nSymbolsStyle != m_nSymbolsStyle ) ||
546
			( bShowMenuImages != m_bShowMenuImages ))
544
		{
547
		{
545
			m_bWasHiContrastMode	= bIsHiContrastMode;
548
			m_bWasHiContrastMode	= bIsHiContrastMode;
549
			m_nSymbolsStyle			= nSymbolsStyle;
546
			m_bShowMenuImages		= bShowMenuImages;
550
			m_bShowMenuImages		= bShowMenuImages;
547
551
548
			USHORT nCount = pActMenu->GetItemCount();
552
			USHORT nCount = pActMenu->GetItemCount();
(-)openoffice.org.orig/sfx2/source/toolbox/tbxitem.cxx (-1 / +5 lines)
Lines 1556-1561 Link Here
1556
	// Determine the current background color of the menus
1556
	// Determine the current background color of the menus
1557
	const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
1557
	const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
1558
	m_bWasHiContrastMode	= rSettings.GetMenuColor().IsDark();
1558
	m_bWasHiContrastMode	= rSettings.GetMenuColor().IsDark();
1559
	m_nSymbolsStyle			= rSettings.GetSymbolsStyle();
1559
	m_bShowMenuImages		= SvtMenuOptions().IsMenuIconsEnabled();
1560
	m_bShowMenuImages		= SvtMenuOptions().IsMenuIconsEnabled();
1560
1561
1561
    SetImage( String() );
1562
    SetImage( String() );
Lines 1831-1842 Link Here
1831
	{
1832
	{
1832
		const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
1833
		const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
1833
		BOOL bIsHiContrastMode	= rSettings.GetMenuColor().IsDark();
1834
		BOOL bIsHiContrastMode	= rSettings.GetMenuColor().IsDark();
1835
		ULONG nSymbolsStyle		= rSettings.GetSymbolsStyle();
1834
		BOOL bShowMenuImages	= SvtMenuOptions().IsMenuIconsEnabled();
1836
		BOOL bShowMenuImages	= SvtMenuOptions().IsMenuIconsEnabled();
1835
1837
1836
		if (( bIsHiContrastMode != m_bWasHiContrastMode ) ||
1838
		if (( bIsHiContrastMode != m_bWasHiContrastMode ) ||
1837
			( bShowMenuImages	!= m_bShowMenuImages	)	 )
1839
			( nSymbolsStyle != m_nSymbolsStyle ) ||
1840
			( bShowMenuImages	!= m_bShowMenuImages))
1838
		{
1841
		{
1839
			m_bWasHiContrastMode = bIsHiContrastMode;
1842
			m_bWasHiContrastMode = bIsHiContrastMode;
1843
			m_nSymbolsStyle		 = nSymbolsStyle;
1840
			m_bShowMenuImages	 = bShowMenuImages;
1844
			m_bShowMenuImages	 = bShowMenuImages;
1841
1845
1842
			USHORT nCount = pActMenu->GetItemCount();
1846
			USHORT nCount = pActMenu->GetItemCount();

Return to issue 86924