diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-04-27 15:29:20 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-04-27 15:31:02 +0200 |
commit | a390d178b0440f5ecc151427c9d05f52c54e8c45 (patch) | |
tree | a04d65356a309149a821d0adb8d8a094a8ba3449 | |
parent | More loplugin:simplifybool (diff) | |
download | core-a390d178b0440f5ecc151427c9d05f52c54e8c45.tar.gz core-a390d178b0440f5ecc151427c9d05f52c54e8c45.zip |
More loplugin:simplifybool
Change-Id: I91848b0a5a5110ca557375d8c432832033237249
-rw-r--r-- | sw/source/core/crsr/findattr.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/docnode/ndtbl1.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/docnode/nodes.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/edit/ednumber.cxx | 4 | ||||
-rw-r--r-- | sw/source/core/layout/pagechg.cxx | 2 | ||||
-rw-r--r-- | sw/source/core/view/viewsh.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/docxattributeoutput.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/wrtw8nds.cxx | 2 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8graf.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par.cxx | 4 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par2.cxx | 6 | ||||
-rw-r--r-- | sw/source/filter/ww8/ww8par6.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/misc/redlndlg.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/uiview/viewdraw.cxx | 2 | ||||
-rw-r--r-- | sw/source/uibase/utlui/numfmtlb.cxx | 2 |
15 files changed, 22 insertions, 22 deletions
diff --git a/sw/source/core/crsr/findattr.cxx b/sw/source/core/crsr/findattr.cxx index cf399d5f55dd..aa3b2edc390b 100644 --- a/sw/source/core/crsr/findattr.cxx +++ b/sw/source/core/crsr/findattr.cxx @@ -82,7 +82,7 @@ bool CmpAttr( const SfxPoolItem& rItem1, const SfxPoolItem& rItem2 ) bNumOffsetEqual = false; } - if (bNumOffsetEqual == false) + if (!bNumOffsetEqual) return false; return static_cast<const SwFmtPageDesc&>(rItem1).GetPageDesc() == static_cast<const SwFmtPageDesc&>(rItem2).GetPageDesc(); diff --git a/sw/source/core/docnode/ndtbl1.cxx b/sw/source/core/docnode/ndtbl1.cxx index 5bf4baae8bee..25705e22922b 100644 --- a/sw/source/core/docnode/ndtbl1.cxx +++ b/sw/source/core/docnode/ndtbl1.cxx @@ -1212,7 +1212,7 @@ bool SwDoc::GetBoxAttr( const SwCursor& rCursor, SfxPoolItem& rToFill ) const } } - if ( false == bRet ) + if ( !bRet ) break; } } diff --git a/sw/source/core/docnode/nodes.cxx b/sw/source/core/docnode/nodes.cxx index 3ae5e3b7ce77..9a54ec9dfa81 100644 --- a/sw/source/core/docnode/nodes.cxx +++ b/sw/source/core/docnode/nodes.cxx @@ -1286,7 +1286,7 @@ SwCntntNode* SwNodes::GoNext(SwNodeIndex *pIdx) const SwNodeIndex aTmp(*pIdx, +1); SwNode* pNd = 0; - while( aTmp < Count()-1 && false == ( pNd = &aTmp.GetNode())->IsCntntNode() ) + while( aTmp < Count()-1 && !( pNd = &aTmp.GetNode())->IsCntntNode() ) ++aTmp; if( aTmp == Count()-1 ) @@ -1303,7 +1303,7 @@ SwCntntNode* SwNodes::GoPrevious(SwNodeIndex *pIdx) const SwNodeIndex aTmp( *pIdx, -1 ); SwNode* pNd = 0; - while( aTmp.GetIndex() && false == ( pNd = &aTmp.GetNode())->IsCntntNode() ) + while( aTmp.GetIndex() && !( pNd = &aTmp.GetNode())->IsCntntNode() ) --aTmp; if( !aTmp.GetIndex() ) diff --git a/sw/source/core/edit/ednumber.cxx b/sw/source/core/edit/ednumber.cxx index ee3b3c835d33..c4e1ab482c9f 100644 --- a/sw/source/core/edit/ednumber.cxx +++ b/sw/source/core/edit/ednumber.cxx @@ -179,7 +179,7 @@ bool SwEditShell::SelectionHasNumber() const { bResult = false; } - if (bResult==false) { + if (!bResult) { break; } } @@ -218,7 +218,7 @@ bool SwEditShell::SelectionHasBullet() const { bResult = pTxtNd->HasBullet(); - if (bResult==false) { + if (!bResult) { break; } } diff --git a/sw/source/core/layout/pagechg.cxx b/sw/source/core/layout/pagechg.cxx index 2cfd85b3c6d6..a81602962ce8 100644 --- a/sw/source/core/layout/pagechg.cxx +++ b/sw/source/core/layout/pagechg.cxx @@ -190,7 +190,7 @@ SwPageFrm::SwPageFrm( SwFrmFmt *pFmt, SwFrm* pSib, SwPageDesc *pPgDsc ) : // create and insert body area if it is not a blank page SwDoc *pDoc = pFmt->GetDoc(); - if ( false == (bEmptyPage = (pFmt == pDoc->GetEmptyPageFmt())) ) + if ( !(bEmptyPage = (pFmt == pDoc->GetEmptyPageFmt())) ) { bEmptyPage = false; Calc(); // so that the PrtArea is correct diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx index 14dfb4354174..1ed7fa0f8278 100644 --- a/sw/source/core/view/viewsh.cxx +++ b/sw/source/core/view/viewsh.cxx @@ -1581,7 +1581,7 @@ bool SwViewShell::CheckInvalidForPaint( const SwRect &rRect ) for ( size_t i = 0; i < pRegion->size(); ++i ) { const SwRect &rTmp = (*pRegion)[i]; - if ( false == (bStop = rTmp.IsOver( VisArea() )) ) + if ( !(bStop = rTmp.IsOver( VisArea() )) ) break; } if ( bStop ) diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx index f45fc1010d42..595cae24efa9 100644 --- a/sw/source/filter/ww8/docxattributeoutput.cxx +++ b/sw/source/filter/ww8/docxattributeoutput.cxx @@ -2691,7 +2691,7 @@ static void impl_borders( FSHelperPtr pSerializer, const SvxBoxItem& rBox, const const SvxBoxItemLine* pBrd = aBorders; bool bExportDistanceFromPageEdge = false; - if ( rOptions.bCheckDistanceSize == true && boxHasLineLargerThan31(rBox) == true ) + if ( rOptions.bCheckDistanceSize && boxHasLineLargerThan31(rBox) ) { // The distance is larger than '31'. This cannot be exported as 'distance from text'. // Instead - it should be exported as 'distance from page edge'. @@ -5461,7 +5461,7 @@ void DocxAttributeOutput::SectionPageBorders( const SwFrmFmt* pFmt, const SwFrmF if ( pBottom || pTop || pLeft || pRight ) { bool bExportDistanceFromPageEdge = false; - if ( boxHasLineLargerThan31(rBox) == true ) + if ( boxHasLineLargerThan31(rBox) ) { // The distance is larger than '31'. This cannot be exported as 'distance from text'. // Instead - it should be exported as 'distance from page edge'. diff --git a/sw/source/filter/ww8/wrtw8nds.cxx b/sw/source/filter/ww8/wrtw8nds.cxx index d787258fce1c..1d5aacbbbb80 100644 --- a/sw/source/filter/ww8/wrtw8nds.cxx +++ b/sw/source/filter/ww8/wrtw8nds.cxx @@ -2946,7 +2946,7 @@ void WW8AttributeOutput::OutputFlyFrame_Impl( const sw::Frame& rFmt, const Point A special case for converting some inline form controls to form fields when in winword 8+ mode */ - if ((bUseEscher == true) && (eType == sw::Frame::eFormControl)) + if (bUseEscher && (eType == sw::Frame::eFormControl)) { if ( m_rWW8Export.MiserableFormFieldExportHack( rFrmFmt ) ) return ; diff --git a/sw/source/filter/ww8/ww8graf.cxx b/sw/source/filter/ww8/ww8graf.cxx index 8249a066f2fd..7bf2a3858be9 100644 --- a/sw/source/filter/ww8/ww8graf.cxx +++ b/sw/source/filter/ww8/ww8graf.cxx @@ -642,7 +642,7 @@ void SwWW8ImplReader::InsertAttrsAsDrawingAttrs(long nStartCp, long nEndCp, if (bStartAttr) { ImportSprm(aRes.pMemPos, aRes.nSprmId); - if (!bDoingSymbol && bSymbol == true) + if (!bDoingSymbol && bSymbol) { bDoingSymbol = true; nStartReplace = nTxtStart; @@ -652,7 +652,7 @@ void SwWW8ImplReader::InsertAttrsAsDrawingAttrs(long nStartCp, long nEndCp, else { EndSprm( aRes.nSprmId ); - if (bSymbol == false && bDoingSymbol) + if (!bSymbol && bDoingSymbol) { bDoingSymbol = false; OUStringBuffer sTemp; diff --git a/sw/source/filter/ww8/ww8par.cxx b/sw/source/filter/ww8/ww8par.cxx index 85922e7c75a5..14ef17bbdbfe 100644 --- a/sw/source/filter/ww8/ww8par.cxx +++ b/sw/source/filter/ww8/ww8par.cxx @@ -2561,11 +2561,11 @@ void SwWW8ImplReader::EndSpecial() StopTable(); maApos.pop_back(); --nInTable; - if (maApos[nInTable] == true) + if (maApos[nInTable]) StopApo(); } - if (maApos[0] == true) + if (maApos[0]) StopApo(); OSL_ENSURE(!nInTable, "unclosed table!"); diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx index 97865c58829d..6c04df25f447 100644 --- a/sw/source/filter/ww8/ww8par2.cxx +++ b/sw/source/filter/ww8/ww8par2.cxx @@ -2246,10 +2246,10 @@ void WW8TabDesc::CalcDefaults() so the default mapping forward wont't work. So map it (and contiguous invalid cells backwards to the last valid cell instead. */ - if (i && pR->bExist[i-1] == false) + if (i && !pR->bExist[i-1]) { sal_uInt16 k=i-1; - while (k && pR->bExist[k] == false) + while (k && !pR->bExist[k]) k--; for (sal_uInt16 n=k+1;n<i;n++) pR->nTransCell[n] = pR->nTransCell[k]; @@ -2338,7 +2338,7 @@ void WW8TabDesc::CreateSwTable(SvxULSpaceItem* pULSpaceItem) } } - if (bSetMinHeight == true) + if (bSetMinHeight) { // minimize Fontsize to minimize height growth of the header/footer // set font size to 1 point to minimize y-growth of Hd/Ft diff --git a/sw/source/filter/ww8/ww8par6.cxx b/sw/source/filter/ww8/ww8par6.cxx index f4781a79068a..9ac0f0e176f0 100644 --- a/sw/source/filter/ww8/ww8par6.cxx +++ b/sw/source/filter/ww8/ww8par6.cxx @@ -4677,7 +4677,7 @@ void SwWW8ImplReader::Read_ParaBackColor(sal_uInt16, const sal_uInt8* pData, sho sal_uInt32 SwWW8ImplReader::ExtractColour(const sal_uInt8* &rpData, bool bVer67) { (void) bVer67; // unused in non-debug - OSL_ENSURE(bVer67 == false, "Impossible"); + OSL_ENSURE(!bVer67, "Impossible"); sal_uInt32 nFore = msfilter::util::BGRToRGB(SVBT32ToUInt32(rpData)); rpData+=4; sal_uInt32 nBack = msfilter::util::BGRToRGB(SVBT32ToUInt32(rpData)); diff --git a/sw/source/uibase/misc/redlndlg.cxx b/sw/source/uibase/misc/redlndlg.cxx index 63847a49c35f..1db1ec86d86b 100644 --- a/sw/source/uibase/misc/redlndlg.cxx +++ b/sw/source/uibase/misc/redlndlg.cxx @@ -777,7 +777,7 @@ void SwRedlineAcceptDlg::CallAcceptReject( bool bSelect, bool bAccept ) ListBoxEntries_t aRedlines; // don't activate - OSL_ENSURE( bInhibitActivate == false, + OSL_ENSURE( !bInhibitActivate, "recursive call of CallAcceptReject?"); bInhibitActivate = true; diff --git a/sw/source/uibase/uiview/viewdraw.cxx b/sw/source/uibase/uiview/viewdraw.cxx index ccc39a4aca63..8ed2185dd44f 100644 --- a/sw/source/uibase/uiview/viewdraw.cxx +++ b/sw/source/uibase/uiview/viewdraw.cxx @@ -709,7 +709,7 @@ bool SwView::HasOnlyObj(SdrObject *pSdrObj, sal_uInt32 eObjInventor) const const size_t nCnt = pList->GetObjCount(); for (size_t i = 0; i < nCnt; ++i) - if ((bRet = HasOnlyObj(pList->GetObj(i), eObjInventor)) == false) + if (!(bRet = HasOnlyObj(pList->GetObj(i), eObjInventor))) break; } else if (eObjInventor == pSdrObj->GetObjInventor()) diff --git a/sw/source/uibase/utlui/numfmtlb.cxx b/sw/source/uibase/utlui/numfmtlb.cxx index 1b9aa58bf62c..c4ad0d190093 100644 --- a/sw/source/uibase/utlui/numfmtlb.cxx +++ b/sw/source/uibase/utlui/numfmtlb.cxx @@ -96,7 +96,7 @@ void NumFormatListBox::Init(short nFormatType, bool bUsrFmts) else eCurLanguage = SvtSysLocale().GetLanguageTag().getLanguageType(); - if (bUsrFmts == false) + if (!bUsrFmts) { pOwnFormatter = new SvNumberFormatter(comphelper::getProcessComponentContext(), eCurLanguage); } |