From bf02636abc2da78dc3bd4e93657fcfa017d530d3 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Fri, 24 Apr 2020 19:18:18 +0200 Subject: loplugin:unusedmethods Change-Id: I7ba901c7d6e1e88d9d2821df4a37ebbea3b63084 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/92874 Tested-by: Jenkins Reviewed-by: Noel Grandin --- svx/source/tbxctrls/Palette.cxx | 37 -------------------------------- svx/source/tbxctrls/SvxColorValueSet.cxx | 21 ------------------ 2 files changed, 58 deletions(-) (limited to 'svx/source') diff --git a/svx/source/tbxctrls/Palette.cxx b/svx/source/tbxctrls/Palette.cxx index 98e69dc2423f..c9b790a9c1e3 100644 --- a/svx/source/tbxctrls/Palette.cxx +++ b/svx/source/tbxctrls/Palette.cxx @@ -38,17 +38,6 @@ PaletteASE::PaletteASE( const OUString &rFPath, const OUString &rFName ) : LoadPalette(); } -void PaletteASE::LoadColorSet( SvxColorValueSet& rColorSet ) -{ - rColorSet.Clear(); - int nIx = 1; - for (const auto& rColor : maColors) - { - rColorSet.InsertItem(nIx, rColor.first, rColor.second); - ++nIx; - } -} - void PaletteASE::LoadColorSet( ColorValueSet& rColorSet ) { rColorSet.Clear(); @@ -208,19 +197,6 @@ const OUString& PaletteGPL::GetPath() return maFPath; } -void PaletteGPL::LoadColorSet( SvxColorValueSet& rColorSet ) -{ - LoadPalette(); - - rColorSet.Clear(); - int nIx = 1; - for (const auto& rColor : maColors) - { - rColorSet.InsertItem(nIx, rColor.first, rColor.second); - ++nIx; - } -} - void PaletteGPL::LoadColorSet( ColorValueSet& rColorSet ) { LoadPalette(); @@ -367,19 +343,6 @@ const OUString& PaletteSOC::GetPath() return maFPath; } -void PaletteSOC::LoadColorSet( SvxColorValueSet& rColorSet ) -{ - if( !mbLoadedPalette ) - { - mbLoadedPalette = true; - mpColorList = XPropertyList::AsColorList(XPropertyList::CreatePropertyListFromURL(XPropertyListType::Color, maFPath)); - (void)mpColorList->Load(); - } - rColorSet.Clear(); - if( mpColorList.is() ) - rColorSet.addEntriesForXColorList( *mpColorList ); -} - void PaletteSOC::LoadColorSet( ColorValueSet& rColorSet ) { if( !mbLoadedPalette ) diff --git a/svx/source/tbxctrls/SvxColorValueSet.cxx b/svx/source/tbxctrls/SvxColorValueSet.cxx index ffdbdab668eb..88fea76fcc19 100644 --- a/svx/source/tbxctrls/SvxColorValueSet.cxx +++ b/svx/source/tbxctrls/SvxColorValueSet.cxx @@ -113,27 +113,6 @@ void ColorValueSet::addEntriesForColorSet(const std::set& rColorSet, cons } } -void SvxColorValueSet::addEntriesForColorSet(const std::set& rColorSet, const OUString& rNamePrefix) -{ - sal_uInt32 nStartIndex = 1; - if(rNamePrefix.getLength() != 0) - { - for(const auto& rColor : rColorSet) - { - InsertItem(nStartIndex, rColor, rNamePrefix + OUString::number(nStartIndex)); - nStartIndex++; - } - } - else - { - for(const auto& rColor : rColorSet) - { - InsertItem(nStartIndex, rColor, ""); - nStartIndex++; - } - } -} - Size ColorValueSet::layoutAllVisible(sal_uInt32 nEntryCount) { if(!nEntryCount) -- cgit