[Libreoffice-commits] core.git: cui/source sc/qa sd/qa sfx2/source svl/qa sw/qa vcl/qa

Stephan Bergmann sbergman at redhat.com
Thu Aug 17 08:25:50 UTC 2017


 cui/source/dialogs/cuicharmap.cxx            |    4 +-
 sc/qa/unit/tiledrendering/tiledrendering.cxx |   24 +++++++--------
 sd/qa/unit/export-tests-ooxml2.cxx           |    2 -
 sfx2/source/control/charmapcontrol.cxx       |    4 +-
 sfx2/source/control/charwin.cxx              |    4 +-
 svl/qa/unit/test_URIHelper.cxx               |   42 ++++++++++++---------------
 sw/qa/extras/ooxmlexport/ooxmlexport2.cxx    |   20 ++++++------
 sw/qa/extras/ooxmlexport/ooxmlexport3.cxx    |    2 -
 sw/qa/extras/ooxmlexport/ooxmlexport4.cxx    |    2 -
 vcl/qa/cppunit/mnemonic.cxx                  |    2 -
 10 files changed, 51 insertions(+), 55 deletions(-)

New commits:
commit a82af43b526c9eca38f74f51d9af0c99c62f8121
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Thu Aug 17 10:23:50 2017 +0200

    Clean up uses of OUString::fromUtf8 around string literals
    
    Change-Id: I9a2990e49c95a01ce505f13408be8c19db1cf5d1

diff --git a/cui/source/dialogs/cuicharmap.cxx b/cui/source/dialogs/cuicharmap.cxx
index fa7a192ccef1..4016afe9ced2 100644
--- a/cui/source/dialogs/cuicharmap.cxx
+++ b/cui/source/dialogs/cuicharmap.cxx
@@ -622,10 +622,10 @@ void SvxCharacterMap::insertCharToDoc(const OUString& sGlyph)
     uno::Reference< uno::XComponentContext > xContext( comphelper::getProcessComponentContext() );
 
     uno::Sequence<beans::PropertyValue> aArgs(2);
-    aArgs[0].Name = OUString::fromUtf8("Symbols");
+    aArgs[0].Name = "Symbols";
     aArgs[0].Value <<= sGlyph;
 
-    aArgs[1].Name = OUString::fromUtf8("FontName");
+    aArgs[1].Name = "FontName";
     aArgs[1].Value <<= aFont.GetFamilyName();
     comphelper::dispatchCommand(".uno:InsertSymbol", aArgs);
 
diff --git a/sc/qa/unit/tiledrendering/tiledrendering.cxx b/sc/qa/unit/tiledrendering/tiledrendering.cxx
index f966627ca1c7..531171e4f23a 100644
--- a/sc/qa/unit/tiledrendering/tiledrendering.cxx
+++ b/sc/qa/unit/tiledrendering/tiledrendering.cxx
@@ -227,9 +227,9 @@ void ScTiledRenderingTest::testRowColumnSelections()
     CPPUNIT_ASSERT_EQUAL(aExpected, aResult);
 
     // Select the 10th row with shift modifier
-    aArgs[0].Name = OUString::fromUtf8("Row");
+    aArgs[0].Name = "Row";
     aArgs[0].Value <<= static_cast<sal_Int32>(10 - 1);
-    aArgs[1].Name = OUString::fromUtf8("Modifier");
+    aArgs[1].Name = "Modifier";
     aArgs[1].Value <<= KEY_SHIFT;
     comphelper::dispatchCommand(".uno:SelectRow", aArgs);
 
@@ -239,9 +239,9 @@ void ScTiledRenderingTest::testRowColumnSelections()
     CPPUNIT_ASSERT_EQUAL(aExpected, aResult);
 
     // Select the 10th row with ctrl modifier
-    aArgs[0].Name = OUString::fromUtf8("Row");
+    aArgs[0].Name = "Row";
     aArgs[0].Value <<= static_cast<sal_Int32>(13 - 1);
-    aArgs[1].Name = OUString::fromUtf8("Modifier");
+    aArgs[1].Name = "Modifier";
     aArgs[1].Value <<= KEY_MOD1;
     comphelper::dispatchCommand(".uno:SelectRow", aArgs);
 
@@ -253,9 +253,9 @@ void ScTiledRenderingTest::testRowColumnSelections()
     // TODO check that we really selected what we wanted here
 
     // Select Column 5 with ctrl modifier
-    aArgs[0].Name = OUString::fromUtf8("Col");
+    aArgs[0].Name = "Col";
     aArgs[0].Value <<= static_cast<sal_Int32>(5 - 1);
-    aArgs[1].Name = OUString::fromUtf8("Modifier");
+    aArgs[1].Name = "Modifier";
     aArgs[1].Value <<= KEY_MOD1;
     comphelper::dispatchCommand(".uno:SelectColumn", aArgs);
 
@@ -268,23 +268,23 @@ void ScTiledRenderingTest::testRowColumnSelections()
 
     // Test for deselection of already selected rows
     // First Deselect Row 13 because copy doesn't work for multiple selections
-    aArgs[0].Name = OUString::fromUtf8("Row");
+    aArgs[0].Name = "Row";
     aArgs[0].Value <<= static_cast<sal_Int32>(13 - 1);
-    aArgs[1].Name = OUString::fromUtf8("Modifier");
+    aArgs[1].Name = "Modifier";
     aArgs[1].Value <<= KEY_MOD1;
     comphelper::dispatchCommand(".uno:SelectRow", aArgs);
 
     // Deselect row 10
-    aArgs[0].Name = OUString::fromUtf8("Row");
+    aArgs[0].Name = "Row";
     aArgs[0].Value <<= static_cast<sal_Int32>(10 - 1);
-    aArgs[1].Name = OUString::fromUtf8("Modifier");
+    aArgs[1].Name = "Modifier";
     aArgs[1].Value <<= KEY_MOD1;
     comphelper::dispatchCommand(".uno:SelectRow", aArgs);
 
     // Click at row 6 holding shift
-    aArgs[0].Name = OUString::fromUtf8("Row");
+    aArgs[0].Name = "Row";
     aArgs[0].Value <<= static_cast<sal_Int32>(6 - 1);
-    aArgs[1].Name = OUString::fromUtf8("Modifier");
+    aArgs[1].Name = "Modifier";
     aArgs[1].Value <<= KEY_SHIFT;
     comphelper::dispatchCommand(".uno:SelectRow", aArgs);
 
diff --git a/sd/qa/unit/export-tests-ooxml2.cxx b/sd/qa/unit/export-tests-ooxml2.cxx
index e94437e17a5a..3d89edec6120 100644
--- a/sd/qa/unit/export-tests-ooxml2.cxx
+++ b/sd/qa/unit/export-tests-ooxml2.cxx
@@ -305,7 +305,7 @@ void SdOOXMLExportTest2::testMathObjectPPT2010()
             "a14");
         assertXPathContent(pXmlDocContent,
             "/p:sld/p:cSld/p:spTree/mc:AlternateContent/mc:Choice/p:sp/p:txBody/a:p/a14:m/m:oMath/m:sSup/m:e/m:r[1]/m:t",
-            OUString::fromUtf8("\xf0\x9d\x91\x8e")); // non-BMP char
+            u"\U0001D44E"); // non-BMP char
 
         const SdrPage *pPage = GetPage(1, xDocShRef);
         const SdrObject* pObj = dynamic_cast<SdrObject*>(pPage->GetObj(0));
diff --git a/sfx2/source/control/charmapcontrol.cxx b/sfx2/source/control/charmapcontrol.cxx
index e9f7d75ae6b5..3551a18c9050 100644
--- a/sfx2/source/control/charmapcontrol.cxx
+++ b/sfx2/source/control/charmapcontrol.cxx
@@ -200,10 +200,10 @@ IMPL_LINK_NOARG(SfxCharmapCtrl, OpenDlgHdl, Button*, void)
     uno::Reference< uno::XComponentContext > xContext( comphelper::getProcessComponentContext() );
 
     uno::Sequence<beans::PropertyValue> aArgs(2);
-    aArgs[0].Name = OUString::fromUtf8("Symbols");
+    aArgs[0].Name = "Symbols";
     aArgs[0].Value <<= OUString();
 
-    aArgs[1].Name = OUString::fromUtf8("FontName");
+    aArgs[1].Name = "FontName";
     aArgs[1].Value <<= OUString();
     //shortcut to launch dialog.. call uno command with empty arguments
     comphelper::dispatchCommand(".uno:InsertSymbol", aArgs);
diff --git a/sfx2/source/control/charwin.cxx b/sfx2/source/control/charwin.cxx
index f827ddae02b4..7a7ec777f124 100644
--- a/sfx2/source/control/charwin.cxx
+++ b/sfx2/source/control/charwin.cxx
@@ -85,10 +85,10 @@ void SvxCharView::InsertCharToDoc()
     uno::Reference< uno::XComponentContext > xContext( comphelper::getProcessComponentContext() );
 
     uno::Sequence<beans::PropertyValue> aArgs(2);
-    aArgs[0].Name = OUString::fromUtf8("Symbols");
+    aArgs[0].Name = "Symbols";
     aArgs[0].Value <<= GetText();
 
-    aArgs[1].Name = OUString::fromUtf8("FontName");
+    aArgs[1].Name = "FontName";
     aArgs[1].Value <<= maFont.GetFamilyName();
 
     comphelper::dispatchCommand(".uno:InsertSymbol", aArgs);
diff --git a/svl/qa/unit/test_URIHelper.cxx b/svl/qa/unit/test_URIHelper.cxx
index dc57dcd51968..66f9efe289e5 100644
--- a/svl/qa/unit/test_URIHelper.cxx
+++ b/svl/qa/unit/test_URIHelper.cxx
@@ -420,58 +420,54 @@ void Test::testResolveIdnaHost() {
     input.clear();
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("Foo.M\xC3\xBCnchen.de");
+    input = u"Foo.M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://Muenchen.de");
+    input = "foo://Muenchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://-M\xC3\xBCnchen.de");
+    input = u"foo://-M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://M\xC3\xBCnchen-.de");
+    input = u"foo://M\u00FCnchen-.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://xn--M\xC3\xBCnchen.de");
+    input = u"foo://xn--M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://xy--M\xC3\xBCnchen.de");
+    input = u"foo://xy--M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://.M\xC3\xBCnchen.de");
+    input = u"foo://.M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://-bar.M\xC3\xBCnchen.de");
+    input = u"foo://-bar.M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://bar-.M\xC3\xBCnchen.de");
+    input = u"foo://bar-.M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://xn--bar.M\xC3\xBCnchen.de");
+    input = u"foo://xn--bar.M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
-    input = OUString::fromUtf8("foo://xy--bar.M\xC3\xBCnchen.de");
+    input = u"foo://xy--bar.M\u00FCnchen.de";
     CPPUNIT_ASSERT_EQUAL(input, URIHelper::resolveIdnaHost(input));
 
     CPPUNIT_ASSERT_EQUAL(
-        OUString::fromUtf8("foo://M\xC3\xBCnchen@xn--mnchen-3ya.de"),
-        URIHelper::resolveIdnaHost(
-            OUString::fromUtf8("foo://M\xC3\xBCnchen@M\xC3\xBCnchen.de")));
+        OUString(u"foo://M\u00FCnchen@xn--mnchen-3ya.de"),
+        URIHelper::resolveIdnaHost(u"foo://M\u00FCnchen@M\u00FCnchen.de"));
 
     CPPUNIT_ASSERT_EQUAL(
-        OUString::fromUtf8("foo://xn--mnchen-3ya.de."),
-        URIHelper::resolveIdnaHost(
-            OUString::fromUtf8("foo://M\xC3\xBCnchen.de.")));
+        OUString("foo://xn--mnchen-3ya.de."),
+        URIHelper::resolveIdnaHost(u"foo://M\u00FCnchen.de."));
 
     CPPUNIT_ASSERT_EQUAL(
-        OUString::fromUtf8("Foo://bar@xn--mnchen-3ya.de:123/?bar#baz"),
-        URIHelper::resolveIdnaHost(
-            OUString::fromUtf8("Foo://bar@M\xC3\xBCnchen.de:123/?bar#baz")));
+        OUString("Foo://bar@xn--mnchen-3ya.de:123/?bar#baz"),
+        URIHelper::resolveIdnaHost(u"Foo://bar@M\u00FCnchen.de:123/?bar#baz"));
 
     CPPUNIT_ASSERT_EQUAL(
-        OUString::fromUtf8("foo://xn--mnchen-3ya.de"),
-        URIHelper::resolveIdnaHost(
-            OUString::fromUtf8("foo://Mu\xCC\x88nchen.de")));
+        OUString("foo://xn--mnchen-3ya.de"),
+        URIHelper::resolveIdnaHost(u"foo://Mu\u0308nchen.de"));
 }
 
 css::uno::Reference< css::uno::XComponentContext > Test::m_context;
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx
index aa06dda59012..72062211959d 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx
@@ -252,12 +252,12 @@ DECLARE_OOXMLEXPORT_TEST(testMathD, "math-d.docx")
 
 DECLARE_OOXMLEXPORT_TEST(testMathEscaping, "math-escaping.docx")
 {
-    CHECK_FORMULA( OUString::fromUtf8("\xe2\x88\x92 \xe2\x88\x9e < x < \xe2\x88\x9e"), getFormula( getRun( getParagraph( 1 ), 1 )));
+    CHECK_FORMULA( u"\u2212 \u221E < x < \u221E", getFormula( getRun( getParagraph( 1 ), 1 )));
 }
 
 DECLARE_OOXMLEXPORT_TEST(testMathLim, "math-lim.docx")
 {
-    CHECK_FORMULA( OUString::fromUtf8("lim from {x \xe2\x86\x92 1} {x}"), getFormula( getRun( getParagraph( 1 ), 1 )));
+    CHECK_FORMULA( u"lim from {x \u2192 1} {x}", getFormula( getRun( getParagraph( 1 ), 1 )));
 }
 
 DECLARE_OOXMLEXPORT_TEST(testMathMatrix, "math-matrix.docx")
@@ -267,32 +267,32 @@ DECLARE_OOXMLEXPORT_TEST(testMathMatrix, "math-matrix.docx")
 
 DECLARE_OOXMLEXPORT_TEST(testMathMso2k7, "math-mso2k7.docx")
 {
-    CHECK_FORMULA( OUString::fromUtf8("A = \xcf\x80 {r} ^ {2}"), getFormula( getRun( getParagraph( 1 ), 1 )));
+    CHECK_FORMULA( u"A = \u03C0 {r} ^ {2}", getFormula( getRun( getParagraph( 1 ), 1 )));
 // TODO check the stack/binom difference
 //    CHECK_FORMULA( "{left (x+a right )} ^ {n} = sum from {k=0} to {n} {left (binom {n} {k} right ) {x} ^ {k} {a} ^ {n-k}}",
     CHECK_FORMULA( "{left (x+a right )} ^ {n} = sum from {k=0} to {n} {left (stack {n # k} right ) {x} ^ {k} {a} ^ {n-k}}",
         getFormula( getRun( getParagraph( 2 ), 1 )));
-    CHECK_FORMULA( OUString::fromUtf8("{left (1+x right )} ^ {n} =1+ {nx} over {1!} + {n left (n-1 right ) {x} ^ {2}} over {2!} +\xe2\x80\xa6"),
+    CHECK_FORMULA( u"{left (1+x right )} ^ {n} =1+ {nx} over {1!} + {n left (n-1 right ) {x} ^ {2}} over {2!} +\u2026",
         getFormula( getRun( getParagraph( 3 ), 1 )));
 // TODO check (cos/sin miss {})
 //    CHECK_FORMULA( "f left (x right ) = {a} rsub {0} + sum from {n=1} to {\xe2\x88\x9e} {left ({a} rsub {n} cos {{n\xcf\x80x} over {L}} + {b} rsub {n} sin {{n\xcf\x80x} over {L}} right )}",
-    CHECK_FORMULA( OUString::fromUtf8("f left (x right ) = {a} rsub {0} + sum from {n=1} to {\xe2\x88\x9e} {left ({a} rsub {n} cos {n\xcf\x80x} over {L} + {b} rsub {n} sin {n\xcf\x80x} over {L} right )}"),
+    CHECK_FORMULA( u"f left (x right ) = {a} rsub {0} + sum from {n=1} to {\u221E} {left ({a} rsub {n} cos {n\u03C0x} over {L} + {b} rsub {n} sin {n\u03C0x} over {L} right )}",
         getFormula( getRun( getParagraph( 4 ), 1 )));
     CHECK_FORMULA( "{a} ^ {2} + {b} ^ {2} = {c} ^ {2}", getFormula( getRun( getParagraph( 5 ), 1 )));
-    CHECK_FORMULA( OUString::fromUtf8("x = {- b \xc2\xb1 sqrt {{b} ^ {2} -4 ac}} over {2 a}"),
+    CHECK_FORMULA( u"x = {- b \u00B1 sqrt {{b} ^ {2} -4 ac}} over {2 a}",
         getFormula( getRun( getParagraph( 6 ), 1 )));
     CHECK_FORMULA(
-        OUString::fromUtf8("{e} ^ {x} =1+ {x} over {1!} + {{x} ^ {2}} over {2!} + {{x} ^ {3}} over {3!} +\xe2\x80\xa6,    -\xe2\x88\x9e<x<\xe2\x88\x9e"),
+        u"{e} ^ {x} =1+ {x} over {1!} + {{x} ^ {2}} over {2!} + {{x} ^ {3}} over {3!} +\u2026,    -\u221E<x<\u221E",
         getFormula( getRun( getParagraph( 7 ), 1 )));
     CHECK_FORMULA(
 //        "sin {\xce\xb1} \xc2\xb1 sin {\xce\xb2} =2 sin {{1} over {2} left (\xce\xb1\xc2\xb1\xce\xb2 right )} cos {{1} over {2} left (\xce\xb1\xe2\x88\x93\xce\xb2 right )}",
 // TODO check (cos/in miss {})
-        OUString::fromUtf8("sin \xce\xb1 \xc2\xb1 sin \xce\xb2 =2 sin {1} over {2} left (\xce\xb1\xc2\xb1\xce\xb2 right ) cos {1} over {2} left (\xce\xb1\xe2\x88\x93\xce\xb2 right )"),
+        u"sin \u03B1 \u00B1 sin \u03B2 =2 sin {1} over {2} left (\u03B1\u00B1\u03B2 right ) cos {1} over {2} left (\u03B1\u2213\u03B2 right )",
         getFormula( getRun( getParagraph( 8 ), 1 )));
     CHECK_FORMULA(
 //        "cos {\xce\xb1} + cos {\xce\xb2} =2 cos {{1} over {2} left (\xce\xb1+\xce\xb2 right )} cos {{1} over {2} left (\xce\xb1-\xce\xb2 right )}",
 // TODO check (cos/sin miss {})
-        OUString::fromUtf8("cos \xce\xb1 + cos \xce\xb2 =2 cos {1} over {2} left (\xce\xb1+\xce\xb2 right ) cos {1} over {2} left (\xce\xb1-\xce\xb2 right )"),
+        u"cos \u03B1 + cos \u03B2 =2 cos {1} over {2} left (\u03B1+\u03B2 right ) cos {1} over {2} left (\u03B1-\u03B2 right )",
         getFormula( getRun( getParagraph( 9 ), 1 )));
 }
 
@@ -580,7 +580,7 @@ DECLARE_OOXMLEXPORT_TEST(testTableStylerPrSz, "table-style-rPr-sz.docx")
 
 DECLARE_OOXMLEXPORT_TEST(testMathLiteral, "math-literal.docx")
 {
-    CHECK_FORMULA( OUString::fromUtf8("iiint from {V} to <?> {\"div\" \"F\"}  dV= llint from {S} to <?> {\"F\" \xe2\x88\x99 \"n \" dS}"),
+    CHECK_FORMULA( u"iiint from {V} to <?> {\"div\" \"F\"}  dV= llint from {S} to <?> {\"F\" \u2219 \"n \" dS}",
         getFormula( getRun( getParagraph( 1 ), 1 )));
 }
 
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport3.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport3.cxx
index 248b139e1c70..85b1b8fef611 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport3.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport3.cxx
@@ -1035,7 +1035,7 @@ DECLARE_OOXMLEXPORT_TEST(testFileOpenInputOutputError,"floatingtbl_with_formula.
       assertXPath(pXmlDoc, "/w:document/w:body/w:p[1]/w:pPr/w:pStyle", "val", "Normal");
 
     // let's also assert that the formula was exported properly
-    assertXPathContent(pXmlDoc, "//wps:txbx/w:txbxContent/w:tbl/w:tr/w:tc[2]/w:p/m:oMath/m:sSubSup/m:e/m:r/m:t", OUString::fromUtf8("\xcf\x83"));
+    assertXPathContent(pXmlDoc, "//wps:txbx/w:txbxContent/w:tbl/w:tr/w:tc[2]/w:p/m:oMath/m:sSubSup/m:e/m:r/m:t", u"\u03C3");
 }
 
 #endif
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
index e7a569cd5090..eff59b4de783 100644
--- a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
+++ b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx
@@ -656,7 +656,7 @@ DECLARE_OOXMLEXPORT_TEST(testDateControl, "date-control.docx")
     assertXPath(pXmlDoc, "/w:document/w:body/w:p/w:sdt/w:sdtPr/w:date", "fullDate", "2014-03-05T00:00:00Z");
     assertXPath(pXmlDoc, "/w:document/w:body/w:p/w:sdt/w:sdtPr/w:date/w:dateFormat", "val", "dddd, dd' de 'MMMM' de 'yyyy");
     assertXPath(pXmlDoc, "/w:document/w:body/w:p/w:sdt/w:sdtPr/w:date/w:lid", "val", "es-ES");
-    assertXPathContent(pXmlDoc, "/w:document/w:body/w:p/w:sdt/w:sdtContent/w:r/w:t", OUString::fromUtf8("mi\xC3\xA9rcoles, 05 de marzo de 2014"));
+    assertXPathContent(pXmlDoc, "/w:document/w:body/w:p/w:sdt/w:sdtContent/w:r/w:t", u"mi\u00E9rcoles, 05 de marzo de 2014");
 
     // check imported control
     uno::Reference<drawing::XControlShape> xControl(getShape(1), uno::UNO_QUERY);
diff --git a/vcl/qa/cppunit/mnemonic.cxx b/vcl/qa/cppunit/mnemonic.cxx
index 4527d2ed1784..0109c1cd0279 100644
--- a/vcl/qa/cppunit/mnemonic.cxx
+++ b/vcl/qa/cppunit/mnemonic.cxx
@@ -33,7 +33,7 @@ void VclMnemonicTest::testMnemonic()
     MnemonicGenerator aGenerator;
 
     {
-        OUString sResult = aGenerator.CreateMnemonic(OUString::fromUtf8(u8"ßa"));
+        OUString sResult = aGenerator.CreateMnemonic(u"ßa");
         CPPUNIT_ASSERT_EQUAL(u'~', sResult[1]);
     }
 


More information about the Libreoffice-commits mailing list