summaryrefslogtreecommitdiff
path: root/UnoControls
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-07-29 15:08:21 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-08-02 14:43:58 +0200
commit1597cc5b3e07dd24cb4cb10b35b1e93545e4b929 (patch)
treef6ed37244e41d23e8a84327b1580e37f3dc18829 /UnoControls
parent0e883d6dbee8d72257f77605ae0c8a1d5bfbf044 (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 'UnoControls')
-rw-r--r--UnoControls/source/controls/progressmonitor.cxx16
-rw-r--r--UnoControls/source/controls/statusindicator.cxx8
2 files changed, 12 insertions, 12 deletions
diff --git a/UnoControls/source/controls/progressmonitor.cxx b/UnoControls/source/controls/progressmonitor.cxx
index fa7ab1aa7098..cf9160ee4556 100644
--- a/UnoControls/source/controls/progressmonitor.cxx
+++ b/UnoControls/source/controls/progressmonitor.cxx
@@ -39,14 +39,14 @@ using namespace ::com::sun::star::awt;
using ::std::vector;
-#define FIXEDTEXT_SERVICENAME "com.sun.star.awt.UnoControlFixedText"
-#define FIXEDTEXT_MODELNAME "com.sun.star.awt.UnoControlFixedTextModel"
-#define CONTROLNAME_TEXT "Text" // identifier the control in container
-#define CONTROLNAME_PROGRESSBAR "ProgressBar"
-#define BUTTON_SERVICENAME "com.sun.star.awt.UnoControlButton"
-#define CONTROLNAME_BUTTON "Button"
-#define BUTTON_MODELNAME "com.sun.star.awt.UnoControlButtonModel"
-#define DEFAULT_BUTTONLABEL "Abbrechen"
+constexpr OUStringLiteral FIXEDTEXT_SERVICENAME = u"com.sun.star.awt.UnoControlFixedText";
+constexpr OUStringLiteral FIXEDTEXT_MODELNAME = u"com.sun.star.awt.UnoControlFixedTextModel";
+constexpr OUStringLiteral CONTROLNAME_TEXT = u"Text"; // identifier the control in container
+constexpr OUStringLiteral CONTROLNAME_PROGRESSBAR = u"ProgressBar";
+constexpr OUStringLiteral BUTTON_SERVICENAME = u"com.sun.star.awt.UnoControlButton";
+constexpr OUStringLiteral CONTROLNAME_BUTTON = u"Button";
+constexpr OUStringLiteral BUTTON_MODELNAME = u"com.sun.star.awt.UnoControlButtonModel";
+constexpr OUStringLiteral DEFAULT_BUTTONLABEL = u"Abbrechen";
namespace unocontrols {
diff --git a/UnoControls/source/controls/statusindicator.cxx b/UnoControls/source/controls/statusindicator.cxx
index 50e5b8078a27..6e5f097981df 100644
--- a/UnoControls/source/controls/statusindicator.cxx
+++ b/UnoControls/source/controls/statusindicator.cxx
@@ -34,10 +34,10 @@ using namespace ::com::sun::star::lang;
using namespace ::com::sun::star::awt;
using namespace ::com::sun::star::task;
-#define FIXEDTEXT_SERVICENAME "com.sun.star.awt.UnoControlFixedText"
-#define FIXEDTEXT_MODELNAME "com.sun.star.awt.UnoControlFixedTextModel"
-#define CONTROLNAME_TEXT "Text" // identifier the control in container
-#define CONTROLNAME_PROGRESSBAR "ProgressBar" // -||-
+constexpr OUStringLiteral FIXEDTEXT_SERVICENAME = u"com.sun.star.awt.UnoControlFixedText";
+constexpr OUStringLiteral FIXEDTEXT_MODELNAME = u"com.sun.star.awt.UnoControlFixedTextModel";
+constexpr OUStringLiteral CONTROLNAME_TEXT = u"Text"; // identifier the control in container
+constexpr OUStringLiteral CONTROLNAME_PROGRESSBAR = u"ProgressBar"; // -||-
namespace unocontrols {