diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-07-29 15:08:21 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-08-02 14:43:58 +0200 |
commit | 1597cc5b3e07dd24cb4cb10b35b1e93545e4b929 (patch) | |
tree | f6ed37244e41d23e8a84327b1580e37f3dc18829 /xmloff/source | |
parent | 0e883d6dbee8d72257f77605ae0c8a1d5bfbf044 (diff) |
convert #defines to OUStringLiteral
mostly by doing
$ git grep -l '#define.*\"' -- *.cxx
| xargs perl -pi -e
's/^#define\s+(\w+)\s+(\".*\")/constexpr OUStringLiteral \1 =
u\2;/g'
Change-Id: Idface893449b0ef2a3c5254865a300585d752fbb
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119669
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'xmloff/source')
-rw-r--r-- | xmloff/source/core/xmlexp.cxx | 6 | ||||
-rw-r--r-- | xmloff/source/core/xmluconv.cxx | 2 | ||||
-rw-r--r-- | xmloff/source/draw/shapeexport.cxx | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/xmloff/source/core/xmlexp.cxx b/xmloff/source/core/xmlexp.cxx index f45afea8aaa5..e877f5b25cbd 100644 --- a/xmloff/source/core/xmlexp.cxx +++ b/xmloff/source/core/xmlexp.cxx @@ -116,10 +116,10 @@ using namespace ::xmloff::token; #define XML_MODEL_SERVICE_MATH "com.sun.star.formula.FormulaProperties" #define XML_MODEL_SERVICE_CHART "com.sun.star.chart.ChartDocument" -#define XML_USEPRETTYPRINTING "UsePrettyPrinting" +constexpr OUStringLiteral XML_USEPRETTYPRINTING = u"UsePrettyPrinting"; -#define XML_EMBEDDEDOBJECTGRAPHIC_URL_BASE "vnd.sun.star.GraphicObject:" -#define XML_EMBEDDEDOBJECT_URL_BASE "vnd.sun.star.EmbeddedObject:" +constexpr OUStringLiteral XML_EMBEDDEDOBJECTGRAPHIC_URL_BASE = u"vnd.sun.star.GraphicObject:"; +constexpr OUStringLiteral XML_EMBEDDEDOBJECT_URL_BASE = u"vnd.sun.star.EmbeddedObject:"; namespace { diff --git a/xmloff/source/core/xmluconv.cxx b/xmloff/source/core/xmluconv.cxx index 9cc7fe68370a..0791532897f0 100644 --- a/xmloff/source/core/xmluconv.cxx +++ b/xmloff/source/core/xmluconv.cxx @@ -60,7 +60,7 @@ using namespace ::xmloff::token; const sal_Int8 XML_MAXDIGITSCOUNT_TIME = 11; -#define XML_NULLDATE "NullDate" +constexpr OUStringLiteral XML_NULLDATE = u"NullDate"; struct SvXMLUnitConverter::Impl { diff --git a/xmloff/source/draw/shapeexport.cxx b/xmloff/source/draw/shapeexport.cxx index 2c757e2b2237..d10a99c67a53 100644 --- a/xmloff/source/draw/shapeexport.cxx +++ b/xmloff/source/draw/shapeexport.cxx @@ -124,7 +124,7 @@ using namespace ::com::sun::star; using namespace ::xmloff::EnhancedCustomShapeToken; using namespace ::xmloff::token; -#define XML_EMBEDDEDOBJECTGRAPHIC_URL_BASE "vnd.sun.star.GraphicObject:" +constexpr OUStringLiteral XML_EMBEDDEDOBJECTGRAPHIC_URL_BASE = u"vnd.sun.star.GraphicObject:"; namespace { |