[Libreoffice-commits] .: cui/source forms/source
Joseph Powers
jpowers at kemper.freedesktop.org
Mon Nov 22 17:55:37 PST 2010
cui/source/customize/cfg.cxx | 18 ++-------------
cui/source/inc/cfg.hxx | 31 +++++++++++++--------------
forms/source/helper/commandimageprovider.cxx | 11 ++++-----
forms/source/inc/commandimageprovider.hxx | 5 +---
forms/source/solar/control/navtoolbar.cxx | 12 +---------
5 files changed, 27 insertions(+), 50 deletions(-)
New commits:
commit 7a518205104fcb6e4a6d7642bae6efe3d1812ca2
Author: Joseph Powers <jpowers27 at cox.net>
Date: Mon Nov 22 17:55:31 2010 -0800
Remove the last of the HC icons
diff --git a/cui/source/customize/cfg.cxx b/cui/source/customize/cfg.cxx
index 75cf7f7..430badc 100644
--- a/cui/source/customize/cfg.cxx
+++ b/cui/source/customize/cfg.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -379,13 +379,6 @@ void InitImageType()
{
theImageType |= css::ui::ImageType::SIZE_LARGE;
}
-
- Window* topwin = Application::GetActiveTopWindow();
- if ( topwin != NULL &&
- topwin->GetSettings().GetStyleSettings().GetHighContrastMode() )
- {
- theImageType |= css::ui::ImageType::COLOR_HIGHCONTRAST;
- }
}
sal_Int16 GetImageType()
@@ -993,7 +986,7 @@ uno::Reference< graphic::XGraphic > GetGraphic(
if ( xImageManager.is() )
{
- // TODO handle large and high contrast graphics
+ // TODO handle large graphics
uno::Sequence< uno::Reference< graphic::XGraphic > > aGraphicSeq;
uno::Sequence< OUString > aImageCmdSeq( 1 );
@@ -1164,7 +1157,7 @@ bool MenuSaveInData::LoadSubMenus(
// Don't access non existing menu configuration!
if ( !xMenuSettings.is() )
return true;
-
+
for ( sal_Int32 nIndex = 0; nIndex < xMenuSettings->getCount(); nIndex++ )
{
uno::Reference< container::XIndexAccess > xSubMenu;
@@ -5063,8 +5056,6 @@ SvxToolbarEntriesListBox::SvxToolbarEntriesListBox(
m_pButtonData = new SvLBoxButtonData( this );
BuildCheckBoxButtonImages( m_pButtonData );
EnableCheckButton( m_pButtonData );
-
- m_bHiContrastMode = GetSettings().GetStyleSettings().GetHighContrastMode();
}
// --------------------------------------------------------
@@ -5139,9 +5130,6 @@ void SvxToolbarEntriesListBox::DataChanged( const DataChangedEvent& rDCEvt )
if (( rDCEvt.GetType() == DATACHANGED_SETTINGS ) &&
( rDCEvt.GetFlags() & SETTINGS_STYLE ))
{
- // We have to reset all images because we change to/from high contrast mode
- m_bHiContrastMode = GetSettings().GetStyleSettings().GetHighContrastMode();
-
BuildCheckBoxButtonImages( m_pButtonData );
Invalidate();
}
diff --git a/cui/source/inc/cfg.hxx b/cui/source/inc/cfg.hxx
index da943a7..b7da6d4 100644
--- a/cui/source/inc/cfg.hxx
+++ b/cui/source/inc/cfg.hxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -137,7 +137,7 @@ public:
::com::sun::star::uno::Reference
< ::com::sun::star::ui::XUIConfigurationManager >
GetParentConfigManager() { return m_xParentCfgMgr; };
-
+
::com::sun::star::uno::Reference
< ::com::sun::star::ui::XImageManager >
GetImageManager() { return m_xImgMgr; };
@@ -271,7 +271,7 @@ public:
bool bParentData = FALSE );
SvxConfigEntry()
- :
+ :
nId( 0 ),
bPopUp( FALSE ),
bStrEdited( FALSE ),
@@ -379,7 +379,7 @@ class SvxDescriptionEdit : public ExtMultiLineEdit
{
private:
Rectangle m_aRealRect;
-
+
public:
SvxDescriptionEdit( Window* pParent, const ResId& _rId );
inline ~SvxDescriptionEdit() {}
@@ -582,7 +582,6 @@ class SvxToolbarEntriesListBox : public SvxMenuEntriesListBox
Size m_aCheckBoxImageSizePixel;
Link m_aChangedListener;
SvLBoxButtonData* m_pButtonData;
- BOOL m_bHiContrastMode;
SvxConfigPage* pPage;
void ChangeVisibility( SvLBoxEntry* pEntry );
@@ -758,7 +757,7 @@ private:
CancelButton aBtnCancel;
HelpButton aBtnHelp;
PushButton aBtnImport;
- PushButton aBtnDelete;
+ PushButton aBtnDelete;
FixedLine aFlSeparator;
sal_uInt16 m_nNextId;
@@ -771,13 +770,13 @@ private:
::com::sun::star::ui::XImageManager > m_xParentImageManager;
::com::sun::star::uno::Reference<
- ::com::sun::star::ui::XImageManager > m_xImportedImageManager;
+ ::com::sun::star::ui::XImageManager > m_xImportedImageManager;
::com::sun::star::uno::Reference<
::com::sun::star::graphic::XGraphicProvider > m_xGraphProvider;
-
+
bool ReplaceGraphicItem( const ::rtl::OUString& aURL );
-
+
bool ImportGraphic( const ::rtl::OUString& aURL );
void ImportGraphics(
@@ -792,8 +791,8 @@ public:
const ::com::sun::star::uno::Reference<
::com::sun::star::ui::XImageManager >& rXImageManager,
const ::com::sun::star::uno::Reference<
- ::com::sun::star::ui::XImageManager >& rXParentImageManager
- );
+ ::com::sun::star::ui::XImageManager >& rXParentImageManager
+ );
~SvxIconSelectorDialog();
@@ -802,19 +801,19 @@ public:
DECL_LINK( SelectHdl, ToolBox * );
DECL_LINK( ImportHdl, PushButton * );
- DECL_LINK( DeleteHdl, PushButton * );
+ DECL_LINK( DeleteHdl, PushButton * );
};
class SvxIconReplacementDialog : public MessBox
{
public:
- SvxIconReplacementDialog(
- Window *pWindow,
+ SvxIconReplacementDialog(
+ Window *pWindow,
const rtl::OUString& aMessage,
bool aYestoAll);
- SvxIconReplacementDialog(
- Window *pWindow,
+ SvxIconReplacementDialog(
+ Window *pWindow,
const rtl::OUString& aMessage );
rtl::OUString ReplaceIconName( const rtl::OUString& );
diff --git a/forms/source/helper/commandimageprovider.cxx b/forms/source/helper/commandimageprovider.cxx
index 504ead7..6b35996 100644
--- a/forms/source/helper/commandimageprovider.cxx
+++ b/forms/source/helper/commandimageprovider.cxx
@@ -1,7 +1,7 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -82,7 +82,7 @@ namespace frm
}
// ICommandImageProvider
- virtual CommandImages getCommandImages( const CommandURLs& _rCommandURLs, const bool _bLarge, const bool _bHiContrast ) const;
+ virtual CommandImages getCommandImages( const CommandURLs& _rCommandURLs, const bool _bLarge ) const;
private:
void impl_init_nothrow( const ::comphelper::ComponentContext& _rContext, const Reference< XModel >& _rxDocument );
@@ -130,15 +130,14 @@ namespace frm
}
//--------------------------------------------------------------------
- CommandImages DocumentCommandImageProvider::getCommandImages( const CommandURLs& _rCommandURLs, const bool _bLarge, const bool _bHiContrast ) const
+ CommandImages DocumentCommandImageProvider::getCommandImages( const CommandURLs& _rCommandURLs, const bool _bLarge ) const
{
const size_t nCommandCount = _rCommandURLs.getLength();
CommandImages aImages( nCommandCount );
try
{
- const sal_Int16 nImageType =
- ( _bLarge ? ImageType::SIZE_LARGE : ImageType::SIZE_DEFAULT )
- + ( _bHiContrast ? ImageType::COLOR_HIGHCONTRAST : ImageType::COLOR_NORMAL );
+ const sal_Int16 nImageType = ImageType::COLOR_NORMAL
+ + ( _bLarge ? ImageType::SIZE_LARGE : ImageType::SIZE_DEFAULT );
Sequence< Reference< XGraphic > > aDocImages( nCommandCount );
Sequence< Reference< XGraphic > > aModImages( nCommandCount );
diff --git a/forms/source/inc/commandimageprovider.hxx b/forms/source/inc/commandimageprovider.hxx
index f17b722..caf19b4 100644
--- a/forms/source/inc/commandimageprovider.hxx
+++ b/forms/source/inc/commandimageprovider.hxx
@@ -1,7 +1,7 @@
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -54,8 +54,7 @@ namespace frm
public:
virtual CommandImages getCommandImages(
const CommandURLs& _rCommandURLs,
- const bool _bLarge,
- const bool _bHiContrast
+ const bool _bLarge
) const = 0;
virtual ~ICommandImageProvider() { }
diff --git a/forms/source/solar/control/navtoolbar.cxx b/forms/source/solar/control/navtoolbar.cxx
index bdc4e98..b1c6f0d 100644
--- a/forms/source/solar/control/navtoolbar.cxx
+++ b/forms/source/solar/control/navtoolbar.cxx
@@ -2,7 +2,7 @@
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
+ *
* Copyright 2000, 2010 Oracle and/or its affiliates.
*
* OpenOffice.org - a multi-platform office productivity suite
@@ -369,8 +369,6 @@ namespace frm
if ( !m_pImageProvider )
return;
- const bool bIsHighContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
-
const USHORT nItemCount = m_pToolbar->GetItemCount();
// collect the FormFeatures in the toolbar
@@ -396,7 +394,7 @@ namespace frm
}
// retrieve the images for the command URLs
- CommandImages aCommandImages = m_pImageProvider->getCommandImages( aCommandURLs, m_eImageSize == eLarge, bIsHighContrast );
+ CommandImages aCommandImages = m_pImageProvider->getCommandImages( aCommandURLs, m_eImageSize == eLarge );
// and set them at the toolbar
CommandImages::const_iterator commandImage = aCommandImages.begin();
@@ -547,9 +545,6 @@ namespace frm
m_pToolbar->SetControlBackground();
forEachItemWindow( &NavigationToolBar::setItemBackground, NULL );
- // the contrast of the background color may have changed, so force
- // the images to be rebuild (high contrast requires a possibly different
- // image set)
implUpdateImages();
}
@@ -560,9 +555,6 @@ namespace frm
m_pToolbar->SetControlBackground( _rColor );
forEachItemWindow( &NavigationToolBar::setItemBackground, &_rColor );
- // the contrast of the background color may have changed, so force
- // the images to be rebuild (high contrast requires a possibly different
- // image set)
implUpdateImages();
}
More information about the Libreoffice-commits
mailing list