From 1f8983592f2a64246090151dca8c03c02027ec2c Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Mon, 25 Apr 2016 16:42:28 +0200 Subject: Some more sal_Bool -> bool Change-Id: Ie056687f7845e3ee133627f8961795f6bd8730f7 --- sw/qa/extras/globalfilter/globalfilter.cxx | 8 ++++---- sw/qa/extras/ooxmlexport/ooxmlexport2.cxx | 6 +++--- sw/qa/extras/ooxmlexport/ooxmlexport4.cxx | 4 ++-- sw/qa/extras/ooxmlexport/ooxmlexport7.cxx | 2 +- sw/qa/extras/ooxmlexport/ooxmlfieldexport.cxx | 4 ++-- sw/qa/extras/ooxmlimport/ooxmlimport.cxx | 12 ++++++------ sw/qa/extras/rtfexport/rtfexport.cxx | 4 ++-- sw/qa/extras/rtfimport/rtfimport.cxx | 24 ++++++++++++------------ sw/qa/extras/ww8export/ww8export.cxx | 2 +- sw/source/filter/ww8/docxattributeoutput.cxx | 4 ++-- sw/source/filter/ww8/docxtablestyleexport.cxx | 4 ++-- 11 files changed, 37 insertions(+), 37 deletions(-) (limited to 'sw') diff --git a/sw/qa/extras/globalfilter/globalfilter.cxx b/sw/qa/extras/globalfilter/globalfilter.cxx index 2ac43bf6a26e..b32f3b857060 100644 --- a/sw/qa/extras/globalfilter/globalfilter.cxx +++ b/sw/qa/extras/globalfilter/globalfilter.cxx @@ -535,19 +535,19 @@ void Test::testCharHighlightODF() { case 1: // non-transparent highlight CPPUNIT_ASSERT_EQUAL(static_cast(64), getProperty(xRun, "CharBackColor")); - CPPUNIT_ASSERT_EQUAL(sal_False, getProperty(xRun, "CharBackTransparent")); + CPPUNIT_ASSERT_EQUAL(false, getProperty(xRun, "CharBackTransparent")); break; case 2: // transparent backcolor CPPUNIT_ASSERT_EQUAL(static_cast(COL_TRANSPARENT), getProperty(xRun, "CharBackColor")); - CPPUNIT_ASSERT_EQUAL(sal_True, getProperty(xRun, "CharBackTransparent")); + CPPUNIT_ASSERT_EQUAL(true, getProperty(xRun, "CharBackTransparent")); break; case 3: // non-transparent backcolor CPPUNIT_ASSERT_EQUAL(static_cast(128), getProperty(xRun, "CharBackColor")); - CPPUNIT_ASSERT_EQUAL(sal_False, getProperty(xRun, "CharBackTransparent")); + CPPUNIT_ASSERT_EQUAL(false, getProperty(xRun, "CharBackTransparent")); break; case 4: // non-transparent highlight again CPPUNIT_ASSERT_EQUAL(static_cast(64), getProperty(xRun, "CharBackColor")); - CPPUNIT_ASSERT_EQUAL(sal_False, getProperty(xRun, "CharBackTransparent")); + CPPUNIT_ASSERT_EQUAL(false, getProperty(xRun, "CharBackTransparent")); break; } } diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx index f751fff5ba38..549755cbaae3 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport2.cxx @@ -661,7 +661,7 @@ DECLARE_OOXMLEXPORT_TEST(testI120928, "i120928.docx") DECLARE_OOXMLEXPORT_TEST(testFdo64826, "fdo64826.docx") { // 'Track-Changes' (Track Revisions) wasn't exported. - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(mxComponent, "RecordChanges"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(mxComponent, "RecordChanges"))); } DECLARE_OOXMLEXPORT_TEST(testPageBackground, "page-background.docx") @@ -812,7 +812,7 @@ DECLARE_OOXMLEXPORT_TEST(testFdo56679, "fdo56679.docx") uno::Reference< text::XTextRange > xParagraph = getParagraph( 1 ); uno::Reference< text::XTextRange > xText = getRun( xParagraph, 2, "This is a simple sentence."); - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xText, "CharUnderlineHasColor"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xText, "CharUnderlineHasColor"))); CPPUNIT_ASSERT_EQUAL(sal_Int32(0xFF0000), getProperty(xText, "CharUnderlineColor")); } @@ -1112,7 +1112,7 @@ DECLARE_OOXMLEXPORT_TEST(testFdo67737, "fdo67737.docx") const beans::PropertyValue& rProp = aProps[i]; if (rProp.Name == "MirroredY") { - CPPUNIT_ASSERT_EQUAL( true, bool(rProp.Value.get()) ); + CPPUNIT_ASSERT_EQUAL( true, bool(rProp.Value.get()) ); return; } } diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx index 7b4e2cd44dda..bc2eab2788df 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport4.cxx @@ -125,8 +125,8 @@ DECLARE_OOXMLEXPORT_TEST(testGroupshapePicture, "groupshape-picture.docx") DECLARE_OOXMLEXPORT_TEST(testAutofit, "autofit.docx") { - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(getShape(1), "TextAutoGrowHeight"))); - CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(getShape(2), "TextAutoGrowHeight"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(getShape(1), "TextAutoGrowHeight"))); + CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(getShape(2), "TextAutoGrowHeight"))); } DECLARE_OOXMLEXPORT_TEST(testTrackChangesDeletedParagraphMark, "testTrackChangesDeletedParagraphMark.docx") diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport7.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport7.cxx index 46c5390c3b74..a7ad4653f619 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport7.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport7.cxx @@ -899,7 +899,7 @@ DECLARE_OOXMLEXPORT_TEST(testfdo79591, "fdo79591.docx") DECLARE_OOXMLEXPORT_TEST(testBnc884615, "bnc884615.docx") { // The problem was that the shape in the header wasn't in the background. - CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(getShape(1), "Opaque"))); + CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(getShape(1), "Opaque"))); } DECLARE_OOXMLEXPORT_TEST(testFdo80894, "TextFrameRotation.docx") diff --git a/sw/qa/extras/ooxmlexport/ooxmlfieldexport.cxx b/sw/qa/extras/ooxmlexport/ooxmlfieldexport.cxx index 09c0840fad08..9af064c457a3 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlfieldexport.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlfieldexport.cxx @@ -86,13 +86,13 @@ DECLARE_OOXMLEXPORT_TEST(testN789482, "n789482.docx") getRun(xParagraph, 1, "Before. "); CPPUNIT_ASSERT_EQUAL(OUString("Delete"), getProperty(getRun(xParagraph, 2), "RedlineType")); - CPPUNIT_ASSERT_EQUAL(sal_True, getProperty(getRun(xParagraph, 2), "IsStart")); + CPPUNIT_ASSERT_EQUAL(true, getProperty(getRun(xParagraph, 2), "IsStart")); getRun(xParagraph, 3, "www.test.com"); CPPUNIT_ASSERT_EQUAL(OUString("http://www.test.com/"), getProperty(getRun(xParagraph, 3), "HyperLinkURL")); CPPUNIT_ASSERT_EQUAL(OUString("Delete"), getProperty(getRun(xParagraph, 4), "RedlineType")); - CPPUNIT_ASSERT_EQUAL(sal_False, getProperty(getRun(xParagraph, 4), "IsStart")); + CPPUNIT_ASSERT_EQUAL(false, getProperty(getRun(xParagraph, 4), "IsStart")); getRun(xParagraph, 5, " After."); } diff --git a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx index 458da1388436..08cc3c4a1593 100644 --- a/sw/qa/extras/ooxmlimport/ooxmlimport.cxx +++ b/sw/qa/extras/ooxmlimport/ooxmlimport.cxx @@ -1398,7 +1398,7 @@ DECLARE_OOXMLIMPORT_TEST(testTableWidth, "table_width.docx") uno::Reference xTablesSupplier(mxComponent, uno::UNO_QUERY); uno::Reference xTables(xTablesSupplier->getTextTables(), uno::UNO_QUERY); // Relative width wasn't recognized during import. - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xTables->getByIndex(0), "IsWidthRelative"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xTables->getByIndex(0), "IsWidthRelative"))); uno::Reference xFramesSupplier(mxComponent, uno::UNO_QUERY); uno::Reference xFrames(xFramesSupplier->getTextFrames(), uno::UNO_QUERY); @@ -1445,7 +1445,7 @@ DECLARE_OOXMLIMPORT_TEST(testN779630, "n779630.docx") CPPUNIT_ASSERT_EQUAL(true, bool(xServiceInfo->supportsService("com.sun.star.form.component.DateField"))); CPPUNIT_ASSERT_EQUAL(OUString("date default text"), getProperty(xPropertySet, "HelpText")); CPPUNIT_ASSERT_EQUAL(sal_Int16(8), getProperty(xPropertySet, "DateFormat")); - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xPropertySet, "Dropdown"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xPropertySet, "Dropdown"))); // Second shape: combo box xControlShape.set(getShape(2), uno::UNO_QUERY); @@ -1454,7 +1454,7 @@ DECLARE_OOXMLIMPORT_TEST(testN779630, "n779630.docx") CPPUNIT_ASSERT_EQUAL(true, bool(xServiceInfo->supportsService("com.sun.star.form.component.ComboBox"))); CPPUNIT_ASSERT_EQUAL(OUString("dropdown default text"), getProperty(xPropertySet, "DefaultText")); CPPUNIT_ASSERT_EQUAL(sal_Int32(2), getProperty< uno::Sequence >(xPropertySet, "StringItemList").getLength()); - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xPropertySet, "Dropdown"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xPropertySet, "Dropdown"))); } DECLARE_OOXMLIMPORT_TEST(testIndentation, "indentation.docx") @@ -1822,9 +1822,9 @@ DECLARE_OOXMLIMPORT_TEST(testWpsOnly, "wps-only.docx") CPPUNIT_ASSERT_EQUAL(text::WrapTextMode_THROUGHT, getProperty(xShape, "Surround")); // This should be in front of text. - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xShape, "Opaque"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xShape, "Opaque"))); // And this should be behind the document. - CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(getShape(2), "Opaque"))); + CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(getShape(2), "Opaque"))); } DECLARE_OOXMLIMPORT_TEST(lineWpsOnly, "line-wps-only.docx") @@ -1888,7 +1888,7 @@ DECLARE_OOXMLIMPORT_TEST(textboxWpgOnly, "textbox-wpg-only.docx") CPPUNIT_ASSERT_EQUAL(text::RelOrientation::PAGE_FRAME, getProperty(xShape, "HoriOrientRelation")); CPPUNIT_ASSERT_EQUAL(text::RelOrientation::PAGE_FRAME, getProperty(xShape, "VertOrientRelation")); // Make sure the shape is not in the background, as we have behindDoc="0" in the doc. - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xShape, "Opaque"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xShape, "Opaque"))); // The 3 paragraphs on the rectangles inside the groupshape ended up in the // body text, make sure we don't have multiple paragraphs there anymore. diff --git a/sw/qa/extras/rtfexport/rtfexport.cxx b/sw/qa/extras/rtfexport/rtfexport.cxx index 58a35c1a0079..c08a47adcd08 100644 --- a/sw/qa/extras/rtfexport/rtfexport.cxx +++ b/sw/qa/extras/rtfexport/rtfexport.cxx @@ -59,7 +59,7 @@ public: bool CjkNumberedListTestHelper(sal_Int16& rValue) { - sal_Bool isNumber = false; + bool isNumber = false; uno::Reference xPara(getParagraph(1)); uno::Reference properties(xPara, uno::UNO_QUERY); properties->getPropertyValue("NumberingIsNumber") >>= isNumber; @@ -696,7 +696,7 @@ DECLARE_RTFEXPORT_TEST(testLineNumbering, "linenumbering.rtf") { uno::Reference xLineNumberingProperties(mxComponent, uno::UNO_QUERY_THROW); uno::Reference xPropertySet = xLineNumberingProperties->getLineNumberingProperties(); - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xPropertySet, "IsOn"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xPropertySet, "IsOn"))); CPPUNIT_ASSERT_EQUAL(sal_Int32(5), getProperty(xPropertySet, "Interval")); } diff --git a/sw/qa/extras/rtfimport/rtfimport.cxx b/sw/qa/extras/rtfimport/rtfimport.cxx index 5fc69e6bf733..a9168c3df51c 100644 --- a/sw/qa/extras/rtfimport/rtfimport.cxx +++ b/sw/qa/extras/rtfimport/rtfimport.cxx @@ -256,8 +256,8 @@ DECLARE_RTFIMPORT_TEST(testN750757, "n750757.rtf") uno::Reference xParaEnumAccess(xTextDocument->getText(), uno::UNO_QUERY); uno::Reference xParaEnum = xParaEnumAccess->createEnumeration(); - CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(xParaEnum->nextElement(), "ParaContextMargin"))); - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xParaEnum->nextElement(), "ParaContextMargin"))); + CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(xParaEnum->nextElement(), "ParaContextMargin"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(xParaEnum->nextElement(), "ParaContextMargin"))); } DECLARE_RTFIMPORT_TEST(testFdo45563, "fdo45563.rtf") @@ -568,7 +568,7 @@ DECLARE_RTFIMPORT_TEST(testFdo49501, "fdo49501.rtf") { uno::Reference xStyle(getStyles("PageStyles")->getByName("Standard"), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(sal_True, getProperty(xStyle, "IsLandscape")); + CPPUNIT_ASSERT_EQUAL(true, getProperty(xStyle, "IsLandscape")); sal_Int32 nExpected(convertTwipToMm100(567)); CPPUNIT_ASSERT_EQUAL(nExpected, getProperty(xStyle, "LeftMargin")); CPPUNIT_ASSERT_EQUAL(nExpected, getProperty(xStyle, "RightMargin")); @@ -1795,8 +1795,8 @@ DECLARE_RTFIMPORT_TEST(testShpzDhgt, "shpz-dhgt.rtf") DECLARE_RTFIMPORT_TEST(testBackground, "background.rtf") { // The first shape wasn't in the foreground. - CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(getShape(1), "Opaque"))); - CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(getShape(2), "Opaque"))); + CPPUNIT_ASSERT_EQUAL(true, bool(getProperty(getShape(1), "Opaque"))); + CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(getShape(2), "Opaque"))); } DECLARE_RTFIMPORT_TEST(testLevelfollow, "levelfollow.rtf") @@ -2452,25 +2452,25 @@ DECLARE_RTFIMPORT_TEST(testLndscpsxn, "lndscpsxn.rtf") xCursor->jumpToFirstPage(); OUString pageStyleName = getProperty(xCursor, "PageStyleName"); uno::Reference xStylePage(pageStyles->getByName(pageStyleName), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(sal_True, getProperty(xStylePage, "IsLandscape")); + CPPUNIT_ASSERT_EQUAL(true, getProperty(xStylePage, "IsLandscape")); // check that the second page has no landscape flag xCursor->jumpToPage(2); pageStyleName = getProperty(xCursor, "PageStyleName"); xStylePage.set(pageStyles->getByName(pageStyleName), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(sal_False, getProperty(xStylePage, "IsLandscape")); + CPPUNIT_ASSERT_EQUAL(false, getProperty(xStylePage, "IsLandscape")); // check that the third page has landscape flag xCursor->jumpToPage(3); pageStyleName = getProperty(xCursor, "PageStyleName"); xStylePage.set(pageStyles->getByName(pageStyleName), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(sal_True, getProperty(xStylePage, "IsLandscape")); + CPPUNIT_ASSERT_EQUAL(true, getProperty(xStylePage, "IsLandscape")); // check that the last page has no landscape flag xCursor->jumpToLastPage(); pageStyleName = getProperty(xCursor, "PageStyleName"); xStylePage.set(pageStyles->getByName(pageStyleName), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(sal_False, getProperty(xStylePage, "IsLandscape")); + CPPUNIT_ASSERT_EQUAL(false, getProperty(xStylePage, "IsLandscape")); } DECLARE_RTFIMPORT_TEST(testLandscape, "landscape.rtf") @@ -2492,19 +2492,19 @@ DECLARE_RTFIMPORT_TEST(testLandscape, "landscape.rtf") xCursor->jumpToFirstPage(); OUString pageStyleName = getProperty(xCursor, "PageStyleName"); uno::Reference xStylePage(pageStyles->getByName(pageStyleName), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(sal_True, getProperty(xStylePage, "IsLandscape")); + CPPUNIT_ASSERT_EQUAL(true, getProperty(xStylePage, "IsLandscape")); // check that the second page has landscape flag xCursor->jumpToPage(2); pageStyleName = getProperty(xCursor, "PageStyleName"); xStylePage.set(pageStyles->getByName(pageStyleName), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(sal_True, getProperty(xStylePage, "IsLandscape")); + CPPUNIT_ASSERT_EQUAL(true, getProperty(xStylePage, "IsLandscape")); // check that the last page has landscape flag xCursor->jumpToLastPage(); pageStyleName = getProperty(xCursor, "PageStyleName"); xStylePage.set(pageStyles->getByName(pageStyleName), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(sal_True, getProperty(xStylePage, "IsLandscape")); + CPPUNIT_ASSERT_EQUAL(true, getProperty(xStylePage, "IsLandscape")); } DECLARE_RTFIMPORT_TEST(testTdf97035, "tdf97035.rtf") diff --git a/sw/qa/extras/ww8export/ww8export.cxx b/sw/qa/extras/ww8export/ww8export.cxx index 60e3fd103ba1..452c8c21854e 100644 --- a/sw/qa/extras/ww8export/ww8export.cxx +++ b/sw/qa/extras/ww8export/ww8export.cxx @@ -216,7 +216,7 @@ DECLARE_WW8EXPORT_TEST(testFdo42144, "fdo42144.odt") { // Footer wasn't disabled -- instead empty footer was exported. uno::Reference xStyle(getStyles("PageStyles")->getByName("Standard"), uno::UNO_QUERY); - CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(xStyle, "FooterIsOn"))); + CPPUNIT_ASSERT_EQUAL(false, bool(getProperty(xStyle, "FooterIsOn"))); } DECLARE_WW8EXPORT_TEST(testCharacterBorder, "charborder.odt") diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx index 383d7c57671c..caccb2dd038a 100644 --- a/sw/source/filter/ww8/docxattributeoutput.cxx +++ b/sw/source/filter/ww8/docxattributeoutput.cxx @@ -5240,9 +5240,9 @@ void DocxAttributeOutput::StartStyle( const OUString& rName, StyleType eType, else if (rGrabBag[i].Name == "locked") bLocked = true; else if (rGrabBag[i].Name == "default") - bDefault = rGrabBag[i].Value.get(); + bDefault = rGrabBag[i].Value.get(); else if (rGrabBag[i].Name == "customStyle") - bCustomStyle = rGrabBag[i].Value.get(); + bCustomStyle = rGrabBag[i].Value.get(); else SAL_WARN("sw.ww8", "Unhandled style property: " << rGrabBag[i].Name); } diff --git a/sw/source/filter/ww8/docxtablestyleexport.cxx b/sw/source/filter/ww8/docxtablestyleexport.cxx index 86e20e9c7ef2..043608caa470 100644 --- a/sw/source/filter/ww8/docxtablestyleexport.cxx +++ b/sw/source/filter/ww8/docxtablestyleexport.cxx @@ -605,9 +605,9 @@ void DocxTableStyleExport::Impl::TableStyle(uno::Sequence& for (sal_Int32 i = 0; i < rStyle.getLength(); ++i) { if (rStyle[i].Name == "default") - bDefault = rStyle[i].Value.get(); + bDefault = rStyle[i].Value.get(); else if (rStyle[i].Name == "customStyle") - bCustomStyle = rStyle[i].Value.get(); + bCustomStyle = rStyle[i].Value.get(); else if (rStyle[i].Name == "styleId") aStyleId = rStyle[i].Value.get(); else if (rStyle[i].Name == "name") -- cgit