summaryrefslogtreecommitdiff
path: root/xmloff/inc
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2020-12-23 10:55:05 +0100
committerStephan Bergmann <sbergman@redhat.com>2020-12-23 14:31:28 +0100
commit747cf9f95f8f97062f9d4566910f97529fbeedc4 (patch)
tree3764b1867eccd80b118d5457a4725c7575994f37 /xmloff/inc
parent554bd2927f525450e96a12e733f16c86c76ac8e6 (diff)
Directly create strings in *::MapTokenToServiceName
...and pass them into XMLTextFieldImportContext and derived ctors. The assert in the XMLTextFieldImportContext ctor is moved up to the two MapTokenToServiceName functions. Change-Id: I75c76cd6129e79ad54ea87e7d3419ca49679875d Reviewed-on: https://gerrit.libreoffice.org/c/core/+/108235 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'xmloff/inc')
-rw-r--r--xmloff/inc/txtfldi.hxx10
-rw-r--r--xmloff/inc/txtvfldi.hxx4
2 files changed, 7 insertions, 7 deletions
diff --git a/xmloff/inc/txtfldi.hxx b/xmloff/inc/txtfldi.hxx
index 6b3aa3365568..8f7e248bddd9 100644
--- a/xmloff/inc/txtfldi.hxx
+++ b/xmloff/inc/txtfldi.hxx
@@ -66,7 +66,7 @@ public:
XMLTextFieldImportContext(
SvXMLImport& rImport, /// XML Import
XMLTextImportHelper& rHlp, /// Text import helper
- const char* pService); /// name of SO API service
+ const OUString& pService); /// name of SO API service
/// process character data: will be collected in member sContentBuffer
virtual void SAL_CALL characters( const OUString& sContent ) override;
@@ -327,7 +327,7 @@ protected:
/// protected constructor: only for subclasses
XMLDatabaseFieldImportContext(SvXMLImport& rImport,
XMLTextImportHelper& rHlp,
- const char* pServiceName,
+ const OUString& pServiceName,
bool bUseDisplay );
public:
@@ -371,7 +371,7 @@ protected:
// for use in child classes
XMLDatabaseNextImportContext(SvXMLImport& rImport,
XMLTextImportHelper& rHlp,
- const char* pServiceName);
+ const OUString& pServiceName);
public:
@@ -463,7 +463,7 @@ protected:
virtual void PrepareField(
const css::uno::Reference< css::beans::XPropertySet> & xPropertySet) override;
- static const char* MapTokenToServiceName(sal_Int32 nElementToken);
+ static OUString MapTokenToServiceName(sal_Int32 nElementToken);
};
/** import docinfo fields with date or time attributes and numberformats */
@@ -711,7 +711,7 @@ private:
virtual void PrepareField(
const css::uno::Reference<css::beans::XPropertySet> & xPropertySet) override;
- static const char* MapTokenToServiceName(sal_Int32 nElement);
+ static OUString MapTokenToServiceName(sal_Int32 nElement);
};
/** import page variable fields (<text:get-page-variable>) */
diff --git a/xmloff/inc/txtvfldi.hxx b/xmloff/inc/txtvfldi.hxx
index 67bc233b77cb..8a288bdfb436 100644
--- a/xmloff/inc/txtvfldi.hxx
+++ b/xmloff/inc/txtvfldi.hxx
@@ -137,7 +137,7 @@ public:
// for XMLTextFieldImportContext:
SvXMLImport& rImport, /// XML Import
XMLTextImportHelper& rHlp, /// text import helper
- const char* pServiceName, /// name of SO API service
+ const OUString& pServiceName, /// name of SO API service
// config variables for PrepareField behavior:
bool bFormula, /// set Formula property
bool bFormulaDefault, /// use content as default for formula
@@ -232,7 +232,7 @@ public:
// for XMLTextFieldImportContext:
SvXMLImport& rImport, /// see XMLTextFieldImportContext
XMLTextImportHelper& rHlp, /// see XMLTextFieldImportContext
- const char* pServiceName, /// see XMLTextFieldImportContext
+ const OUString& pServiceName, /// see XMLTextFieldImportContext
// for finding appropriate field master (see endFastElement())
VarType eVarType, /// variable type
// config variables: