summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2017-10-09 11:21:08 +0200
committerTomaž Vajngerl <quikee@gmail.com>2017-10-16 15:32:34 +0200
commit0716aca251bbb64fab6c8697ee0a2215461f1019 (patch)
treeb93985678a5cc3dfdeab8474b2707413be0a19ee /sw
parent92fad9596efb5ecbc756bdcc5f53ea4a417ece62 (diff)
tscp: move getting the current policy type to class. helper
Change-Id: I54afcca1c1fc1a27458c75ab9fd3405d6f7e9239 Reviewed-on: https://gerrit.libreoffice.org/43360 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/edit/edfcol.cxx14
1 files changed, 3 insertions, 11 deletions
diff --git a/sw/source/core/edit/edfcol.cxx b/sw/source/core/edit/edfcol.cxx
index 6b90dbde76ca..37b774264aec 100644
--- a/sw/source/core/edit/edfcol.cxx
+++ b/sw/source/core/edit/edfcol.cxx
@@ -465,14 +465,6 @@ static void lcl_removeAllProperties(uno::Reference<beans::XPropertyContainer> co
}
}
-// from classification helper
-SfxClassificationPolicyType getPolicyType()
-{
- sal_Int32 nPolicyTypeNumber = officecfg::Office::Common::Classification::Policy::get();
- auto eType = static_cast<SfxClassificationPolicyType>(nPolicyTypeNumber);
- return eType;
-}
-
bool addOrInsertDocumentProperty(uno::Reference<beans::XPropertyContainer> const & rxPropertyContainer, OUString const & rsKey, OUString const & rsValue)
{
uno::Reference<beans::XPropertySet> xPropertySet(rxPropertyContainer, uno::UNO_QUERY);
@@ -528,11 +520,11 @@ void SwEditShell::ApplyAdvancedClassification(std::vector<svx::ClassificationRes
{
if (rResult.meType == svx::ClassificationType::CATEGORY)
{
- aHelper.SetBACName(rResult.msString, getPolicyType());
+ aHelper.SetBACName(rResult.msString, SfxClassificationHelper::getPolicyType());
}
}
- OUString sPolicy = SfxClassificationHelper::policyTypeToString(getPolicyType());
+ OUString sPolicy = SfxClassificationHelper::policyTypeToString(SfxClassificationHelper::getPolicyType());
std::vector<OUString> aUsedPageStyles = lcl_getUsedPageStyles(this);
for (const OUString& rPageStyleName : aUsedPageStyles)
@@ -637,7 +629,7 @@ std::vector<svx::ClassificationResult> SwEditShell::CollectAdvancedClassificatio
uno::Reference<document::XDocumentProperties> xDocumentProperties = SfxObjectShell::Current()->getDocProperties();
uno::Reference<beans::XPropertyContainer> xPropertyContainer = xDocumentProperties->getUserDefinedProperties();
- OUString sPolicy = SfxClassificationHelper::policyTypeToString(getPolicyType());
+ OUString sPolicy = SfxClassificationHelper::policyTypeToString(SfxClassificationHelper::getPolicyType());
sal_Int32 nParagraph = 1;
while (xParagraphs->hasMoreElements())