summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorKohei Yoshida <kohei.yoshida@collabora.com>2014-12-08 10:46:01 -0500
committerKohei Yoshida <kohei.yoshida@collabora.com>2014-12-08 10:47:59 -0500
commitab61d71c8b59facc0910016dc098cdf78ebd47b4 (patch)
tree7116f50178ae8be8dc00a7f455a54b1c4cde5cc3 /sw
parent1256809ba235e1813b38bb7e96d8f1a6c5b6499f (diff)
Build fix (for gcc 4.7).
Change-Id: Ib52cfc8ba45361277ef8e0b6021a03c3ff8ae668
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/extras/globalfilter/globalfilter.cxx16
1 files changed, 7 insertions, 9 deletions
diff --git a/sw/qa/extras/globalfilter/globalfilter.cxx b/sw/qa/extras/globalfilter/globalfilter.cxx
index c4b98117a1c3..43b213be8148 100644
--- a/sw/qa/extras/globalfilter/globalfilter.cxx
+++ b/sw/qa/extras/globalfilter/globalfilter.cxx
@@ -186,7 +186,7 @@ void Test::testImageWithSpecialID()
// Check how LO handles when the imported graphic's ID is different from that one
// which is generated by LO.
- const OUString aFilterNames[] = {
+ const char* aFilterNames[] = {
"writer8",
"Rich Text Format",
"MS Word 97",
@@ -208,7 +208,7 @@ void Test::testImageWithSpecialID()
uno::Reference<frame::XStorable> xStorable(mxComponent, uno::UNO_QUERY);
utl::MediaDescriptor aMediaDescriptor;
- aMediaDescriptor["FilterName"] <<= aFilterNames[nFilter];
+ aMediaDescriptor["FilterName"] <<= OUString::createFromAscii(aFilterNames[nFilter]);
utl::TempFile aTempFile;
aTempFile.EnableKillingFile();
@@ -221,8 +221,7 @@ void Test::testImageWithSpecialID()
uno::Reference<drawing::XDrawPageSupplier> xDrawPageSupplier(mxComponent, uno::UNO_QUERY);
uno::Reference<container::XIndexAccess> xDraws(xDrawPageSupplier->getDrawPage(), uno::UNO_QUERY);
- const OString sFailedMessage = OString("Failed on filter: ")
- + OUStringToOString(aFilterNames[nFilter], RTL_TEXTENCODING_ASCII_US);
+ const OString sFailedMessage = OString("Failed on filter: ") + aFilterNames[nFilter];
CPPUNIT_ASSERT_EQUAL_MESSAGE(sFailedMessage.getStr(), static_cast<sal_Int32>(2), xDraws->getCount());
uno::Reference<drawing::XShape> xImage = getShape(1);
@@ -268,7 +267,7 @@ void Test::testGraphicShape()
// There are two kind of images in Writer: 1) Writer specific handled by SwGrfNode and
// 2) graphic shape handled by SdrGrafObj (e.g. after copy&paste from Impress).
- const OUString aFilterNames[] = {
+ const char* aFilterNames[] = {
"writer8",
"Rich Text Format",
"MS Word 97",
@@ -290,7 +289,7 @@ void Test::testGraphicShape()
uno::Reference<frame::XStorable> xStorable(mxComponent, uno::UNO_QUERY);
utl::MediaDescriptor aMediaDescriptor;
- aMediaDescriptor["FilterName"] <<= aFilterNames[nFilter];
+ aMediaDescriptor["FilterName"] <<= OUString::createFromAscii(aFilterNames[nFilter]);
utl::TempFile aTempFile;
aTempFile.EnableKillingFile();
@@ -303,8 +302,7 @@ void Test::testGraphicShape()
uno::Reference<drawing::XDrawPageSupplier> xDrawPageSupplier(mxComponent, uno::UNO_QUERY);
uno::Reference<container::XIndexAccess> xDraws(xDrawPageSupplier->getDrawPage(), uno::UNO_QUERY);
- const OString sFailedMessage = OString("Failed on filter: ")
- + OUStringToOString(aFilterNames[nFilter], RTL_TEXTENCODING_ASCII_US);
+ const OString sFailedMessage = OString("Failed on filter: ") + aFilterNames[nFilter];
CPPUNIT_ASSERT_EQUAL_MESSAGE(sFailedMessage.getStr(), static_cast<sal_Int32>(2), xDraws->getCount());
uno::Reference<drawing::XShape> xImage = getShape(1);
@@ -327,7 +325,7 @@ void Test::testGraphicShape()
}
// MS filters make this kind of linked images broken !?
- if( aFilterNames[nFilter] != "writer8" )
+ if( OUString::createFromAscii(aFilterNames[nFilter]) != OUString("writer8") )
return;
// Second image is a linked one