summaryrefslogtreecommitdiff
path: root/svx
diff options
context:
space:
mode:
Diffstat (limited to 'svx')
-rw-r--r--svx/source/tbxctrls/PaletteManager.cxx4
-rw-r--r--svx/source/tbxctrls/SvxColorValueSet.cxx10
2 files changed, 7 insertions, 7 deletions
diff --git a/svx/source/tbxctrls/PaletteManager.cxx b/svx/source/tbxctrls/PaletteManager.cxx
index f5ad05161ae4..8d0a21147fe5 100644
--- a/svx/source/tbxctrls/PaletteManager.cxx
+++ b/svx/source/tbxctrls/PaletteManager.cxx
@@ -104,10 +104,10 @@ void PaletteManager::ReloadColorSet(SvxColorValueSet &rColorSet)
else if( mnCurrentPalette == mnNumOfPalettes - 1 )
{
// Add doc colors to palette
- std::vector<Color> aColors = pDocSh->GetDocColors();
+ std::set<Color> aColors = pDocSh->GetDocColors();
mnColorCount = aColors.size();
rColorSet.Clear();
- rColorSet.addEntriesForColorVector(aColors, SVX_RESSTR( RID_SVXSTR_DOC_COLOR_PREFIX ) + " " );
+ rColorSet.addEntriesForColorSet(aColors, SVX_RESSTR( RID_SVXSTR_DOC_COLOR_PREFIX ) + " " );
}
else
{
diff --git a/svx/source/tbxctrls/SvxColorValueSet.cxx b/svx/source/tbxctrls/SvxColorValueSet.cxx
index 29b805675e97..e1bc89c12385 100644
--- a/svx/source/tbxctrls/SvxColorValueSet.cxx
+++ b/svx/source/tbxctrls/SvxColorValueSet.cxx
@@ -80,20 +80,20 @@ void SvxColorValueSet::addEntriesForXColorList(const XColorList& rXColorList, sa
}
}
-void SvxColorValueSet::addEntriesForColorVector(const std::vector<Color>& rColorVector, const OUString& rNamePrefix, sal_uInt32 nStartIndex)
+void SvxColorValueSet::addEntriesForColorSet(const std::set<Color>& rColorSet, const OUString& rNamePrefix, sal_uInt32 nStartIndex)
{
if(rNamePrefix.getLength() != 0)
{
- for(std::vector<Color>::const_iterator it = rColorVector.begin();
- it != rColorVector.end(); ++it, nStartIndex++)
+ for(std::set<Color>::const_iterator it = rColorSet.begin();
+ it != rColorSet.end(); ++it, nStartIndex++)
{
InsertItem(nStartIndex, *it, rNamePrefix + OUString::number(nStartIndex));
}
}
else
{
- for(std::vector<Color>::const_iterator it = rColorVector.begin();
- it != rColorVector.end(); ++it, nStartIndex++)
+ for(std::set<Color>::const_iterator it = rColorSet.begin();
+ it != rColorSet.end(); ++it, nStartIndex++)
{
InsertItem(nStartIndex, *it, "");
}