vcl/source/gdi/WidgetDefinition.cxx |   17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)

New commits:
commit fd975e8bb561f80d62398545b019c876a0d43832
Author:     Arnaud VERSINI <arnaud.vers...@pm.me>
AuthorDate: Sun Jul 27 17:34:13 2025 +0200
Commit:     Arnaud Versini <arnaud.vers...@pm.me>
CommitDate: Wed Jul 30 08:38:50 2025 +0200

    vcl : no need to use a OString for comparison
    
    Change-Id: I396c5a553f9d645ee630c10f939121b1dab3b6a4
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188437
    Reviewed-by: Arnaud Versini <arnaud.vers...@pm.me>
    Tested-by: Jenkins

diff --git a/vcl/source/gdi/WidgetDefinition.cxx 
b/vcl/source/gdi/WidgetDefinition.cxx
index 1c8fb1321ecd..5dd8eb26aef8 100644
--- a/vcl/source/gdi/WidgetDefinition.cxx
+++ b/vcl/source/gdi/WidgetDefinition.cxx
@@ -8,6 +8,7 @@
  *
  */
 
+#include <string_view>
 #include <utility>
 #include <widgetdraw/WidgetDefinition.hxx>
 
@@ -70,7 +71,7 @@ WidgetDefinitionPart::getStates(ControlType eType, 
ControlPart ePart, ControlSta
             bAdd = false;
         }
 
-        OString sExtra = "any"_ostr;
+        std::string_view sExtra = "any";
 
         switch (eType)
         {
@@ -80,13 +81,13 @@ WidgetDefinitionPart::getStates(ControlType eType, 
ControlPart ePart, ControlSta
 
                 if (rTabItemValue.isLeftAligned() && 
rTabItemValue.isRightAligned()
                     && rTabItemValue.isFirst() && rTabItemValue.isLast())
-                    sExtra = "first_last"_ostr;
+                    sExtra = "first_last";
                 else if (rTabItemValue.isLeftAligned() || 
rTabItemValue.isFirst())
-                    sExtra = "first"_ostr;
+                    sExtra = "first";
                 else if (rTabItemValue.isRightAligned() || 
rTabItemValue.isLast())
-                    sExtra = "last"_ostr;
+                    sExtra = "last";
                 else
-                    sExtra = "middle"_ostr;
+                    sExtra = "middle";
             }
             break;
             case ControlType::ListHeader:
@@ -94,9 +95,9 @@ WidgetDefinitionPart::getStates(ControlType eType, 
ControlPart ePart, ControlSta
                 if (ePart == ControlPart::Arrow)
                 {
                     if (rValue.getNumericVal() == 1)
-                        sExtra = "down"_ostr;
+                        sExtra = "down";
                     else
-                        sExtra = "up"_ostr;
+                        sExtra = "up";
                 }
             }
             break;
@@ -104,7 +105,7 @@ WidgetDefinitionPart::getStates(ControlType eType, 
ControlPart ePart, ControlSta
             {
                 auto const& rPushButtonValue = static_cast<PushButtonValue 
const&>(rValue);
                 if (rPushButtonValue.mbIsAction)
-                    sExtra = "action"_ostr;
+                    sExtra = "action";
             }
             break;
             default:

Reply via email to