diff options
author | Caolán McNamara <caolanm@redhat.com> | 2010-11-16 10:22:33 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2010-11-16 10:22:33 +0000 |
commit | 956892c545f984886611b9467dc9b175b616c938 (patch) | |
tree | a692e7fc97ddf3198969d43f7e56bd0eb14571ba | |
parent | a14172b2ece38a6c7e0c5b08f02896a3f6e32df2 (diff) |
remove logically redundant highcontrast code
-rw-r--r-- | sc/inc/global.hxx | 6 | ||||
-rw-r--r-- | sc/inc/sc.hrc | 11 | ||||
-rw-r--r-- | sc/source/core/data/global.cxx | 8 | ||||
-rw-r--r-- | sc/source/ui/inc/content.hxx | 1 | ||||
-rw-r--r-- | sc/source/ui/inc/navipi.hxx | 1 | ||||
-rw-r--r-- | sc/source/ui/inc/tptable.hxx | 2 | ||||
-rw-r--r-- | sc/source/ui/navipi/content.cxx | 1 | ||||
-rw-r--r-- | sc/source/ui/navipi/navipi.cxx | 13 | ||||
-rw-r--r-- | sc/source/ui/navipi/navipi.hrc | 3 | ||||
-rw-r--r-- | sc/source/ui/pagedlg/pagedlg.hrc | 3 | ||||
-rw-r--r-- | sc/source/ui/pagedlg/tptable.cxx | 7 | ||||
-rw-r--r-- | sc/source/ui/unoobj/targuno.cxx | 3 | ||||
-rw-r--r-- | sc/source/ui/view/olinewin.cxx | 2 |
13 files changed, 18 insertions, 43 deletions
diff --git a/sc/inc/global.hxx b/sc/inc/global.hxx index 6afa7ddf3dec..9ee2050d4b73 100644 --- a/sc/inc/global.hxx +++ b/sc/inc/global.hxx @@ -549,7 +549,6 @@ class ScGlobal static SvxBrushItem* pProtectedBrushItem; static ImageList* pOutlineBitmaps; - static ImageList* pOutlineBitmapsHC; static ScFunctionList* pStarCalcFunctionList; static ScFunctionMgr* pStarCalcFunctionMgr; @@ -633,9 +632,8 @@ public: SC_DLLPUBLIC static const String& GetEmptyString(); static const String& GetScDocString(); - /** Returns the specified image list with outline symbols. - @param bHC false = standard symbols; true = high contrast symbols. */ - static ImageList* GetOutlineSymbols( bool bHC ); + /** Returns the specified image list with outline symbols. */ + static ImageList* GetOutlineSymbols(); static bool HasStarCalcFunctionList(); static ScFunctionList* GetStarCalcFunctionList(); diff --git a/sc/inc/sc.hrc b/sc/inc/sc.hrc index 07a1f79627b4..4ac855b39b5b 100644 --- a/sc/inc/sc.hrc +++ b/sc/inc/sc.hrc @@ -1178,8 +1178,9 @@ #define RID_GRAPHIC_OBJECTBAR (SC_RESOURCE_START+54) // free // free -#define RID_IMAGELIST_H_NAVCONT (SC_RESOURCE_START+57) -#define RID_OUTLINEBITMAPS_H (SC_RESOURCE_START+58) +// free +// free +// free #define RID_MEDIA_OBJECTBAR (SC_RESOURCE_START+60) #define RID_POPUP_MEDIA (SC_RESOURCE_START+61) #define RID_FUNCTION_CATEGORIES (SC_RESOURCE_START+62) @@ -1442,9 +1443,9 @@ #define RID_IMG_DROP_URL (BMP_START + 2) #define RID_IMG_DROP_LINK (BMP_START + 3) #define RID_IMG_DROP_COPY (BMP_START + 4) -#define RID_IMG_H_DROP_URL (BMP_START + 5) -#define RID_IMG_H_DROP_LINK (BMP_START + 6) -#define RID_IMG_H_DROP_COPY (BMP_START + 7) +// free +// free +// free #define RID_IMG_SELECT_CURRENT (BMP_START + 8) #define RID_IMG_UNSELECT_CURRENT (BMP_START + 9) diff --git a/sc/source/core/data/global.cxx b/sc/source/core/data/global.cxx index d762e099bad5..e503d3185401 100644 --- a/sc/source/core/data/global.cxx +++ b/sc/source/core/data/global.cxx @@ -125,7 +125,6 @@ SvxBrushItem* ScGlobal::pEmbeddedBrushItem = NULL; SvxBrushItem* ScGlobal::pProtectedBrushItem = NULL; ImageList* ScGlobal::pOutlineBitmaps = NULL; -ImageList* ScGlobal::pOutlineBitmapsHC = NULL; ScFunctionList* ScGlobal::pStarCalcFunctionList = NULL; ScFunctionMgr* ScGlobal::pStarCalcFunctionMgr = NULL; @@ -523,11 +522,11 @@ const String& ScGlobal::GetEmptyString() return *pEmptyString; } -ImageList* ScGlobal::GetOutlineSymbols( bool bHC ) +ImageList* ScGlobal::GetOutlineSymbols() { - ImageList*& rpImageList = bHC ? pOutlineBitmapsHC : pOutlineBitmaps; + ImageList*& rpImageList = pOutlineBitmaps; if( !rpImageList ) - rpImageList = new ImageList( ScResId( bHC ? RID_OUTLINEBITMAPS_H : RID_OUTLINEBITMAPS ) ); + rpImageList = new ImageList( ScResId( RID_OUTLINEBITMAPS ) ); return rpImageList; } @@ -659,7 +658,6 @@ void ScGlobal::Clear() DELETEZ(pEmbeddedBrushItem); DELETEZ(pProtectedBrushItem); DELETEZ(pOutlineBitmaps); - DELETEZ(pOutlineBitmapsHC); // DELETEZ(pAnchorBitmap); // DELETEZ(pGrayAnchorBitmap); DELETEZ(pEnglishFormatter); diff --git a/sc/source/ui/inc/content.hxx b/sc/source/ui/inc/content.hxx index 952215ffbdd6..03924cc998cf 100644 --- a/sc/source/ui/inc/content.hxx +++ b/sc/source/ui/inc/content.hxx @@ -61,7 +61,6 @@ class ScContentTree : public SvTreeListBox { ScNavigatorDlg* pParentWindow; ImageList aEntryImages; - ImageList aHCEntryImages; SvLBoxEntry* pRootNodes[SC_CONTENT_COUNT]; USHORT nRootType; // als Root eingestellt String aManualDoc; // im Navigator umgeschaltet (Title) diff --git a/sc/source/ui/inc/navipi.hxx b/sc/source/ui/inc/navipi.hxx index 6b804589e145..7d3559e3de9b 100644 --- a/sc/source/ui/inc/navipi.hxx +++ b/sc/source/ui/inc/navipi.hxx @@ -244,7 +244,6 @@ private: SfxBindings& rBindings; // must be first member ImageList aCmdImageList; // must be before aTbxCmd - ImageList aCmdImageListH; FixedInfo aFtCol; ColumnEdit aEdCol; FixedInfo aFtRow; diff --git a/sc/source/ui/inc/tptable.hxx b/sc/source/ui/inc/tptable.hxx index 007fb3f795c1..b1b988811d6e 100644 --- a/sc/source/ui/inc/tptable.hxx +++ b/sc/source/ui/inc/tptable.hxx @@ -78,8 +78,6 @@ private: FixedImage aBmpPageDir; Image aImgLeftRight; Image aImgTopDown; - Image aImgLeftRightHC; - Image aImgTopDownHC; CheckBox aBtnPageNo; NumericField aEdPageNo; diff --git a/sc/source/ui/navipi/content.cxx b/sc/source/ui/navipi/content.cxx index e48ec2127392..f9ccc650a5a1 100644 --- a/sc/source/ui/navipi/content.cxx +++ b/sc/source/ui/navipi/content.cxx @@ -128,7 +128,6 @@ ScDocShell* ScContentTree::GetManualOrCurrent() ScContentTree::ScContentTree( Window* pParent, const ResId& rResId ) : SvTreeListBox ( pParent, rResId ), aEntryImages ( ScResId( RID_IMAGELIST_NAVCONT ) ), - aHCEntryImages ( ScResId( RID_IMAGELIST_H_NAVCONT ) ), nRootType ( SC_CONTENT_ROOT ), bHiddenDoc ( FALSE ), pHiddenDocument ( NULL ) diff --git a/sc/source/ui/navipi/navipi.cxx b/sc/source/ui/navipi/navipi.cxx index f3b53f5818a6..ae10df13c469 100644 --- a/sc/source/ui/navipi/navipi.cxx +++ b/sc/source/ui/navipi/navipi.cxx @@ -515,23 +515,19 @@ void CommandToolBox::UpdateButtons() CheckItem( IID_CHANGEROOT, bRootSet ); } - BOOL bHC = GetSettings().GetStyleSettings().GetHighContrastMode(); - USHORT nImageId = 0; switch ( rDlg.nDropMode ) { - case SC_DROPMODE_URL: nImageId = bHC ? RID_IMG_H_DROP_URL : RID_IMG_DROP_URL; break; - case SC_DROPMODE_LINK: nImageId = bHC ? RID_IMG_H_DROP_LINK : RID_IMG_DROP_LINK; break; - case SC_DROPMODE_COPY: nImageId = bHC ? RID_IMG_H_DROP_COPY : RID_IMG_DROP_COPY; break; + case SC_DROPMODE_URL: nImageId = RID_IMG_DROP_URL; break; + case SC_DROPMODE_LINK: nImageId = RID_IMG_DROP_LINK; break; + case SC_DROPMODE_COPY: nImageId = RID_IMG_DROP_COPY; break; } SetItemImage( IID_DROPMODE, Image(ScResId(nImageId)) ); } void CommandToolBox::InitImageList() { - BOOL bHC = GetSettings().GetStyleSettings().GetHighContrastMode(); - - ImageList& rImgLst = bHC ? rDlg.aCmdImageListH : rDlg.aCmdImageList; + ImageList& rImgLst = rDlg.aCmdImageList; USHORT nCount = GetItemCount(); for (USHORT i = 0; i < nCount; i++) @@ -660,7 +656,6 @@ ScNavigatorDlg::ScNavigatorDlg( SfxBindings* pB, SfxChildWindowContext* pCW, Win Window( pParent, ScResId(RID_SCDLG_NAVIGATOR) ), rBindings ( *pB ), // is used in CommandToolBox ctor aCmdImageList( ScResId( IL_CMD ) ), - aCmdImageListH( ScResId( ILH_CMD ) ), aFtCol ( this, ScResId( FT_COL ) ), aEdCol ( this, ScResId( ED_COL ) ), aFtRow ( this, ScResId( FT_ROW ) ), diff --git a/sc/source/ui/navipi/navipi.hrc b/sc/source/ui/navipi/navipi.hrc index 0adb65a5a042..3ca5bb07c130 100644 --- a/sc/source/ui/navipi/navipi.hrc +++ b/sc/source/ui/navipi/navipi.hrc @@ -45,9 +45,6 @@ #define STR_QHLP_SCEN_LISTBOX 15 #define STR_QHLP_SCEN_COMMENT 16 #define IL_CMD 17 -#define ILH_CMD 18 - - #define IID_AREAS 1 #define IID_DBAREAS 2 diff --git a/sc/source/ui/pagedlg/pagedlg.hrc b/sc/source/ui/pagedlg/pagedlg.hrc index 2f3593c2f6d1..0c26340599a1 100644 --- a/sc/source/ui/pagedlg/pagedlg.hrc +++ b/sc/source/ui/pagedlg/pagedlg.hrc @@ -71,9 +71,6 @@ #define FT_SCALEPAGEHEIGHT 53 #define FT_SCALEPAGENUM 54 -#define IMG_LEFTRIGHT_H 41 -#define IMG_TOPDOWN_H 42 - // List box entries "Scaling mode" #define SC_TPTABLE_SCALE_PERCENT 0 #define SC_TPTABLE_SCALE_TO 1 diff --git a/sc/source/ui/pagedlg/tptable.cxx b/sc/source/ui/pagedlg/tptable.cxx index a85ef657a3e1..4e00378b4cec 100644 --- a/sc/source/ui/pagedlg/tptable.cxx +++ b/sc/source/ui/pagedlg/tptable.cxx @@ -128,8 +128,6 @@ ScTablePage::ScTablePage( Window* pParent, const SfxItemSet& rCoreAttrs ) : aBmpPageDir ( this, ScResId( BMP_PAGEDIR ) ), aImgLeftRight ( ScResId( IMG_LEFTRIGHT ) ), aImgTopDown ( ScResId( IMG_TOPDOWN ) ), - aImgLeftRightHC ( ScResId( IMG_LEFTRIGHT_H ) ), - aImgTopDownHC ( ScResId( IMG_TOPDOWN_H ) ), aBtnPageNo ( this, ScResId( BTN_PAGENO ) ), aEdPageNo ( this, ScResId( ED_PAGENO ) ), aFlPrint ( this, ScResId( FL_PRINT ) ), @@ -169,11 +167,8 @@ ScTablePage::ScTablePage( Window* pParent, const SfxItemSet& rCoreAttrs ) : void ScTablePage::ShowImage() { - bool bHC = GetSettings().GetStyleSettings().GetHighContrastMode(); bool bLeftRight = aBtnLeftRight.IsChecked(); - aBmpPageDir.SetImage( bHC ? - (bLeftRight ? aImgLeftRightHC : aImgTopDownHC) : - (bLeftRight ? aImgLeftRight : aImgTopDown) ); + aBmpPageDir.SetImage( (bLeftRight ? aImgLeftRight : aImgTopDown) ); } // ----------------------------------------------------------------------- diff --git a/sc/source/ui/unoobj/targuno.cxx b/sc/source/ui/unoobj/targuno.cxx index 6509b03d864d..c239c489c5a2 100644 --- a/sc/source/ui/unoobj/targuno.cxx +++ b/sc/source/ui/unoobj/targuno.cxx @@ -243,8 +243,7 @@ void ScLinkTargetTypeObj::SetLinkTargetBitmap( uno::Any& rRet, sal_uInt16 nType } if (nImgId) { - BOOL bHighContrast = Application::GetSettings().GetStyleSettings().GetHighContrastMode(); - ImageList aEntryImages( ScResId( bHighContrast ? RID_IMAGELIST_H_NAVCONT : RID_IMAGELIST_NAVCONT ) ); + ImageList aEntryImages( ScResId( RID_IMAGELIST_NAVCONT ) ); const Image& rImage = aEntryImages.GetImage( nImgId ); rRet <<= uno::Reference< awt::XBitmap > (VCLUnoHelper::CreateBitmap( rImage.GetBitmapEx() )); } diff --git a/sc/source/ui/view/olinewin.cxx b/sc/source/ui/view/olinewin.cxx index 9fd8e497d3b7..642aaa63e9b2 100644 --- a/sc/source/ui/view/olinewin.cxx +++ b/sc/source/ui/view/olinewin.cxx @@ -165,7 +165,7 @@ void ScOutlineWindow::InitSettings() const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings(); SetBackground( rStyleSettings.GetFaceColor() ); maLineColor = rStyleSettings.GetButtonTextColor(); - mpSymbols = ScGlobal::GetOutlineSymbols( rStyleSettings.GetHighContrastMode() ); + mpSymbols = ScGlobal::GetOutlineSymbols(); Invalidate(); } |