From 08ab1f46b192a188935fdffbefdc9f3973583cdf Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Sat, 24 Feb 2018 13:47:25 +0200 Subject: loplugin:oncevar extend to tools/gen.hxx types Change-Id: I5c75875da44334569c02e2ff039b33c38397a0a2 Reviewed-on: https://gerrit.libreoffice.org/50283 Tested-by: Jenkins Reviewed-by: Noel Grandin --- cui/source/dialogs/hlmarkwn.cxx | 3 +-- cui/source/options/optcolor.cxx | 3 +-- cui/source/tabpages/tptrans.cxx | 3 +-- 3 files changed, 3 insertions(+), 6 deletions(-) (limited to 'cui') diff --git a/cui/source/dialogs/hlmarkwn.cxx b/cui/source/dialogs/hlmarkwn.cxx index ee011732a24f..d05d4fb5efe0 100644 --- a/cui/source/dialogs/hlmarkwn.cxx +++ b/cui/source/dialogs/hlmarkwn.cxx @@ -359,7 +359,6 @@ int SvxHlinkDlgMarkWnd::FillTree( const uno::Reference< container::XNameAccess > const sal_uLong nLinks = aNames.getLength(); const OUString* pNames = aNames.getConstArray(); - Color aMaskColor( COL_LIGHTMAGENTA ); const OUString aProp_LinkDisplayName( "LinkDisplayName" ); const OUString aProp_LinkTarget( "com.sun.star.document.LinkTarget" ); const OUString aProp_LinkDisplayBitmap( "LinkDisplayBitmap" ); @@ -410,7 +409,7 @@ int SvxHlinkDlgMarkWnd::FillTree( const uno::Reference< container::XNameAccess > aXBitmap( xTarget->getPropertyValue( aProp_LinkDisplayBitmap ), uno::UNO_QUERY ); if( aXBitmap.is() ) { - Image aBmp(BitmapEx(VCLUnoHelper::GetBitmap(aXBitmap).GetBitmap(), aMaskColor)); + Image aBmp(BitmapEx(VCLUnoHelper::GetBitmap(aXBitmap).GetBitmap(), /*mask*/COL_LIGHTMAGENTA)); // insert Displayname into treelist with bitmaps pEntry = mpLbTree->InsertEntry ( aStrDisplayname, aBmp, aBmp, diff --git a/cui/source/options/optcolor.cxx b/cui/source/options/optcolor.cxx index 1e8e4c5b2dc3..49d0d3dc79af 100644 --- a/cui/source/options/optcolor.cxx +++ b/cui/source/options/optcolor.cxx @@ -547,8 +547,7 @@ void ColorConfigWindow_Impl::CreateEntries() void ColorConfigWindow_Impl::SetAppearance () { - Color TempColor(COL_TRANSPARENT); - Wallpaper const aTransparentWall(TempColor); + Wallpaper const aTransparentWall(COL_TRANSPARENT); StyleSettings const& rStyleSettings = GetSettings().GetStyleSettings(); Color const aBackColor = rStyleSettings.GetHighContrastMode() ? rStyleSettings.GetShadowColor() : Color(COL_LIGHTGRAY); diff --git a/cui/source/tabpages/tptrans.cxx b/cui/source/tabpages/tptrans.cxx index bf8ce4d9ff02..553e94d232f3 100644 --- a/cui/source/tabpages/tptrans.cxx +++ b/cui/source/tabpages/tptrans.cxx @@ -374,8 +374,7 @@ bool SvxTransparenceTabPage::FillItemSet(SfxItemSet* rAttrs) // disable unused XFillFloatTransparenceItem if(bSwitchOffGradient && (bGradActive || bGradUsed)) { - Color aColor(COL_BLACK); - XGradient aGrad(aColor, Color(COL_WHITE)); + XGradient aGrad(COL_BLACK, Color(COL_WHITE)); aGrad.SetStartIntens(100); aGrad.SetEndIntens(100); XFillFloatTransparenceItem aItem(aGrad); -- cgit