diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-06-22 10:21:21 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-06-28 10:47:34 +0200 |
commit | bfc1600c6ade6f006eb774bffe7caa9c948e8603 (patch) | |
tree | c660fa18fc6a9e5f05c3cc58fa34411cdc4f4257 /sw | |
parent | f9514beb9bfed51aee69227797e74504afed31c6 (diff) |
loplugin:indentation improve checks for brace alignment
Change-Id: I333100fda7e181f68f36b03279b3fbb8cb768310
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117615
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
34 files changed, 93 insertions, 93 deletions
diff --git a/sw/qa/extras/ooxmlexport/ooxmlexport8.cxx b/sw/qa/extras/ooxmlexport/ooxmlexport8.cxx index 0faed8c2ac02..1c2250afc7bb 100644 --- a/sw/qa/extras/ooxmlexport/ooxmlexport8.cxx +++ b/sw/qa/extras/ooxmlexport/ooxmlexport8.cxx @@ -390,13 +390,13 @@ note that the indexes may get off as the implementation evolves, C++ code search for( int i = 0; i < numbering.getLength(); ++i ) - { + { if( numbering[ i ].Name == "NumberingType" ) - { + { numbering[ i ].Value >>= numberingType; break; - } } + } CPPUNIT_ASSERT_EQUAL( style::NumberingType::ARABIC, numberingType ); } diff --git a/sw/source/core/access/accframebase.cxx b/sw/source/core/access/accframebase.cxx index 6f1e73a12338..505cb5c37e1b 100644 --- a/sw/source/core/access/accframebase.cxx +++ b/sw/source/core/access/accframebase.cxx @@ -95,7 +95,7 @@ SwNodeType SwAccessibleFrameBase::GetNodeType( const SwFlyFrame *pFlyFrame ) SwNodeType nType = SwNodeType::Text; if( pFlyFrame->Lower() ) { - if( pFlyFrame->Lower()->IsNoTextFrame() ) + if( pFlyFrame->Lower()->IsNoTextFrame() ) { const SwNoTextFrame *const pContentFrame = static_cast<const SwNoTextFrame *>(pFlyFrame->Lower()); diff --git a/sw/source/core/access/accmap.cxx b/sw/source/core/access/accmap.cxx index 4479ce52e38c..a3a029342692 100644 --- a/sw/source/core/access/accmap.cxx +++ b/sw/source/core/access/accmap.cxx @@ -3325,7 +3325,7 @@ std::unique_ptr<SwAccessibleSelectedParas_Impl> SwAccessibleMap::BuildSelectedPa // loop on all text frames registered at the text node. SwIterator<SwTextFrame, SwTextNode, sw::IteratorMode::UnwrapMulti> aIter(*pTextNode); for( SwTextFrame* pTextFrame = aIter.First(); pTextFrame; pTextFrame = aIter.Next() ) - { + { uno::WeakReference < XAccessible > xWeakAcc; SwAccessibleContextMap_Impl::iterator aMapIter = mpFrameMap->find( pTextFrame ); @@ -3348,10 +3348,10 @@ std::unique_ptr<SwAccessibleSelectedParas_Impl> SwAccessibleMap::BuildSelectedPa // sw_redlinehide: should be idempotent for multiple nodes in a merged para pRetSelectedParas->emplace( xWeakAcc, aDataEntry ); } - } } } } + } // prepare next turn: get next cursor in ring pCursor = pCursor->GetNext(); diff --git a/sw/source/core/crsr/pam.cxx b/sw/source/core/crsr/pam.cxx index f6e55168315a..cb0a624bb83e 100644 --- a/sw/source/core/crsr/pam.cxx +++ b/sw/source/core/crsr/pam.cxx @@ -846,9 +846,9 @@ SwContentNode* GetNode( SwPaM & rPam, bool& rbFirst, SwMoveFnCollection const & pNd->FindSectionNode()->GetSection().IsProtect() ) ) - { - pNd = nullptr; - } + { + pNd = nullptr; + } } } diff --git a/sw/source/core/crsr/viscrs.cxx b/sw/source/core/crsr/viscrs.cxx index 280bbae9ef82..4d60a0d6e573 100644 --- a/sw/source/core/crsr/viscrs.cxx +++ b/sw/source/core/crsr/viscrs.cxx @@ -253,7 +253,7 @@ void SwVisibleCursor::SetPosAndShow(SfxViewShell const * pViewShell) pWrong = pNode->GetGrammarCheck(); if (pWrong) bIsWrong = pWrong->InWrongWord(nBegin,nLen) && !pNode->IsSymbolAt(nBegin); - } + } } } diff --git a/sw/source/core/doc/DocumentRedlineManager.cxx b/sw/source/core/doc/DocumentRedlineManager.cxx index 6079ddcc88f2..2699b1818560 100644 --- a/sw/source/core/doc/DocumentRedlineManager.cxx +++ b/sw/source/core/doc/DocumentRedlineManager.cxx @@ -92,7 +92,7 @@ using namespace com::sun::star; OSL_ENSURE( ( *(j->GetPoint()) != *(j->GetMark()) ) || ( j->GetContentIdx() != nullptr ), ERROR_PREFIX "empty redline" ); - } + } // verify proper redline sorting for( size_t n = 1; n < rTable.size(); ++n ) diff --git a/sw/source/core/doc/doccorr.cxx b/sw/source/core/doc/doccorr.cxx index 2c8ce7eec4c0..0014bb814f93 100644 --- a/sw/source/core/doc/doccorr.cxx +++ b/sw/source/core/doc/doccorr.cxx @@ -276,7 +276,7 @@ void PaMCorrRel( const SwNodeIndex &rOldNode, if( pCursorShell->IsTableMode() ) lcl_PaMCorrRel1( pCursorShell->GetTableCrs(), pOldNode, aNewPos, nCntIdx ); - } + } } rDoc.cleanupUnoCursorTable(); diff --git a/sw/source/core/layout/dbg_lay.cxx b/sw/source/core/layout/dbg_lay.cxx index 6391f97343d8..180125bb3b61 100644 --- a/sw/source/core/layout/dbg_lay.cxx +++ b/sw/source/core/layout/dbg_lay.cxx @@ -720,8 +720,8 @@ void SwImplProtocol::Record_( const SwFrame* pFrame, PROT nFunction, DbgAction n { aOut.append(' '); aOut.append(static_cast<sal_Int64>(lcl_GetFrameId(static_cast<SwFrame*>(pParam)))); - } - break; + } + break; case PROT::FileInit: FileInit(); aOut.append("Initialize"); break; diff --git a/sw/source/core/layout/fly.cxx b/sw/source/core/layout/fly.cxx index dfaef977b10a..1ae5bae8496e 100644 --- a/sw/source/core/layout/fly.cxx +++ b/sw/source/core/layout/fly.cxx @@ -981,10 +981,10 @@ void SwFlyFrame::UpdateAttr_( const SfxPoolItem *pOld, const SfxPoolItem *pNew, { SwRootFrame* pLayout = getRootFrame(); if( pLayout && pLayout->IsAnyShellAccessible() ) - { - pSh->Imp()->DisposeAccessibleFrame( this ); - pSh->Imp()->AddAccessibleFrame( this ); - } + { + pSh->Imp()->DisposeAccessibleFrame( this ); + pSh->Imp()->AddAccessibleFrame( this ); + } } // #i28701# - perform reorder of object lists // at anchor frame and at page frame. diff --git a/sw/source/core/layout/flycnt.cxx b/sw/source/core/layout/flycnt.cxx index 8cfb9524365c..c49a12cec791 100644 --- a/sw/source/core/layout/flycnt.cxx +++ b/sw/source/core/layout/flycnt.cxx @@ -843,16 +843,16 @@ static const SwFrame * lcl_CalcDownDist( SwDistance &rRet, { if( pLay->IsVertical() ) { - if ( pLay->IsVertLR() ) - { + if ( pLay->IsVertLR() ) + { nFrameTop = pLay->getFrameArea().Left(); nPrtHeight = pLay->getFramePrintArea().Width(); - } - else - { + } + else + { nFrameTop = pLay->getFrameArea().Left() + pLay->getFrameArea().Width(); nPrtHeight = pLay->getFramePrintArea().Width(); - } + } } else { diff --git a/sw/source/core/layout/frmtool.cxx b/sw/source/core/layout/frmtool.cxx index 03c1f1bbfe02..c50061bcf68e 100644 --- a/sw/source/core/layout/frmtool.cxx +++ b/sw/source/core/layout/frmtool.cxx @@ -3459,9 +3459,9 @@ void Notify_Background( const SdrObject* pObj, pFly->getFrameArea().Top() <= rRect.Bottom() && pFly->getFrameArea().Right() >= rRect.Left() && pFly->getFrameArea().Left() <= rRect.Right() ) - { + { pFly->InvalidateSize(); - } + } } // Flys above myself might sidestep if they have an automatic // alignment. This happens independently of my attributes since diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx index 982cd95f98af..d8a293c54ca1 100644 --- a/sw/source/core/layout/paintfrm.cxx +++ b/sw/source/core/layout/paintfrm.cxx @@ -7074,7 +7074,7 @@ void SwLayoutFrame::RefreshExtraData( const SwRect &rRect ) const pFly->getFrameArea().Bottom() >= rRect.Top() ) pFly->RefreshExtraData( rRect ); } - } + } pCnt = pCnt->GetNextContentFrame(); } } diff --git a/sw/source/core/text/EnhancedPDFExportHelper.cxx b/sw/source/core/text/EnhancedPDFExportHelper.cxx index 53c07abe8c0f..778f23046826 100644 --- a/sw/source/core/text/EnhancedPDFExportHelper.cxx +++ b/sw/source/core/text/EnhancedPDFExportHelper.cxx @@ -2324,35 +2324,35 @@ void SwEnhancedPDFExportHelper::MakeHeaderFooterLinks( vcl::PDFExtOutDevData& rP SwIterator<SwTextFrame, SwTextNode, sw::IteratorMode::UnwrapMulti> aIter(rTNd); for ( SwTextFrame* pTmpFrame = aIter.First(); pTmpFrame; pTmpFrame = aIter.Next() ) + { + // Add offset to current page: + const SwPageFrame* pPageFrame = pTmpFrame->FindPageFrame(); + SwRect aHFLinkRect( rLinkRect ); + aHFLinkRect.Pos() = pPageFrame->getFrameArea().Pos() + aOffset; + + // #i97135# the gcc_x64 optimizer gets aHFLinkRect != rLinkRect wrong + // fool it by comparing the position only (the width and height are the + // same anyway) + if ( aHFLinkRect.Pos() != rLinkRect.Pos() ) { - // Add offset to current page: - const SwPageFrame* pPageFrame = pTmpFrame->FindPageFrame(); - SwRect aHFLinkRect( rLinkRect ); - aHFLinkRect.Pos() = pPageFrame->getFrameArea().Pos() + aOffset; - - // #i97135# the gcc_x64 optimizer gets aHFLinkRect != rLinkRect wrong - // fool it by comparing the position only (the width and height are the - // same anyway) - if ( aHFLinkRect.Pos() != rLinkRect.Pos() ) - { - // Link PageNums - std::vector<sal_Int32> aHFLinkPageNums = CalcOutputPageNums( aHFLinkRect ); + // Link PageNums + std::vector<sal_Int32> aHFLinkPageNums = CalcOutputPageNums( aHFLinkRect ); - for (sal_Int32 aHFLinkPageNum : aHFLinkPageNums) - { - // Link Export - tools::Rectangle aRect(SwRectToPDFRect(pPageFrame, aHFLinkRect.SVRect())); - const sal_Int32 nHFLinkId = - rPDFExtOutDevData.CreateLink(aRect, aHFLinkPageNum); + for (sal_Int32 aHFLinkPageNum : aHFLinkPageNums) + { + // Link Export + tools::Rectangle aRect(SwRectToPDFRect(pPageFrame, aHFLinkRect.SVRect())); + const sal_Int32 nHFLinkId = + rPDFExtOutDevData.CreateLink(aRect, aHFLinkPageNum); - // Connect Link and Destination: - if ( bIntern ) - rPDFExtOutDevData.SetLinkDest( nHFLinkId, nDestId ); - else - rPDFExtOutDevData.SetLinkURL( nHFLinkId, rURL ); - } + // Connect Link and Destination: + if ( bIntern ) + rPDFExtOutDevData.SetLinkDest( nHFLinkId, nDestId ); + else + rPDFExtOutDevData.SetLinkURL( nHFLinkId, rURL ); } } + } } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/sw/source/core/text/frmform.cxx b/sw/source/core/text/frmform.cxx index 82f2a8dcd893..111afe6a0f89 100644 --- a/sw/source/core/text/frmform.cxx +++ b/sw/source/core/text/frmform.cxx @@ -456,7 +456,7 @@ void SwTextFrame::AdjustFrame( const SwTwips nChgHght, bool bHasToFit ) else nRstHeight = getFrameArea().Left() + getFrameArea().Width() - ( GetUpper()->getFrameArea().Left() + GetUpper()->getFramePrintArea().Left() ); - } + } else nRstHeight = GetUpper()->getFrameArea().Top() + GetUpper()->getFramePrintArea().Top() diff --git a/sw/source/core/text/itrcrsr.cxx b/sw/source/core/text/itrcrsr.cxx index 2974826154bb..8f94315a2c5c 100644 --- a/sw/source/core/text/itrcrsr.cxx +++ b/sw/source/core/text/itrcrsr.cxx @@ -935,7 +935,7 @@ void SwTextCursor::GetCharRect_( SwRect* pOrig, TextFrameIndex const nOfst, { nX -= GetInfo().GetFont()->GetRightBorderSpace(); } - } + } } bWidth = false; break; diff --git a/sw/source/core/text/porlay.cxx b/sw/source/core/text/porlay.cxx index 95809edf540d..a66e69d88f59 100644 --- a/sw/source/core/text/porlay.cxx +++ b/sw/source/core/text/porlay.cxx @@ -1507,7 +1507,7 @@ void SwScriptInfo::InitScriptInfo(const SwTextNode& rNode, // check if next character is Reh or Yeh-like sal_Unicode cNextCh = rWord[ nIdx + 1 ]; if ( isRehChar ( cNextCh ) || isYehChar ( cNextCh )) - { + { SAL_WARN_IF( 0 == cPrevCh, "sw.core", "No previous character" ); // check if character is connectable to previous character, if ( lcl_ConnectToPrev( cCh, cPrevCh ) ) diff --git a/sw/source/core/txtnode/atrflyin.cxx b/sw/source/core/txtnode/atrflyin.cxx index 7c1562ad49c3..bb42a0853cba 100644 --- a/sw/source/core/txtnode/atrflyin.cxx +++ b/sw/source/core/txtnode/atrflyin.cxx @@ -266,7 +266,7 @@ SwFlyInContentFrame *SwTextFlyCnt::GetFlyFrame_( const SwFrame *pCurrFrame ) while ( pFirst->IsFollow() ) pFirst = pFirst->FindMaster(); do - { + { SwTextFrame *pTmp = pFirst; do { if( static_cast<SwFlyFrame*>(pFrame)->GetAnchorFrame() == static_cast<SwFrame*>(pTmp) ) diff --git a/sw/source/core/unocore/unodraw.cxx b/sw/source/core/unocore/unodraw.cxx index 3348abee8fe1..cd8e799fee00 100644 --- a/sw/source/core/unocore/unodraw.cxx +++ b/sw/source/core/unocore/unodraw.cxx @@ -350,7 +350,7 @@ uno::Reference< drawing::XShape > SwFmDrawPage::CreateShape( SdrObject *pObj ) c return xRet; } } - } + } else { // own block - temporary object has to be destroyed before diff --git a/sw/source/core/unocore/unoportenum.cxx b/sw/source/core/unocore/unoportenum.cxx index 9c9ef1ec44d9..d34adfeb86f8 100644 --- a/sw/source/core/unocore/unoportenum.cxx +++ b/sw/source/core/unocore/unoportenum.cxx @@ -806,7 +806,7 @@ lcl_ExportHints( switch( nAttrWhich ) { case RES_TXTATR_FIELD: - if(!bRightMoveForbidden) + if(!bRightMoveForbidden) { pUnoCursor->Right(1); if( *pUnoCursor->GetMark() == *pUnoCursor->GetPoint() ) @@ -1066,7 +1066,7 @@ static void lcl_FillRedlineArray( if( pRedline->HasMark() && pRedline->End()->nNode == nOwnNode ) rRedArr.insert( std::make_shared<SwXRedlinePortion_Impl>( pRedline, false ) ); - } + } } static void lcl_FillSoftPageBreakArray( diff --git a/sw/source/core/unocore/unostyle.cxx b/sw/source/core/unocore/unostyle.cxx index ac72abefd161..a6a14abef2dc 100644 --- a/sw/source/core/unocore/unostyle.cxx +++ b/sw/source/core/unocore/unostyle.cxx @@ -3729,7 +3729,7 @@ uno::Reference< style::XAutoStyle > SwXAutoStyleFamily::insertStyle( OSL_FAIL( "Illegal argument" ); } } - } + } // clear parent again aSet.SetParent(nullptr); diff --git a/sw/source/filter/ww8/wrtww8.cxx b/sw/source/filter/ww8/wrtww8.cxx index 9f2daa129d53..cbb32e7e2e82 100644 --- a/sw/source/filter/ww8/wrtww8.cxx +++ b/sw/source/filter/ww8/wrtww8.cxx @@ -2378,9 +2378,9 @@ void WW8AttributeOutput::TableDefinition( ww8::WW8TableNodeInfoInner::Pointer_t ww8::GridColsPtr pGridCols = GetGridCols( pTableTextNodeInfoInner ); for ( const auto nCol : *pGridCols ) - { + { m_rWW8Export.InsUInt16( o3tl::narrowing<sal_uInt16>(nCol) + nTableOffset ); - } + } /* TCs */ ww8::RowSpansPtr pRowSpans = pTableTextNodeInfoInner->getRowSpansOfRow(); diff --git a/sw/source/filter/ww8/ww8glsy.cxx b/sw/source/filter/ww8/ww8glsy.cxx index 012a4c4075f9..4384a4e69bdc 100644 --- a/sw/source/filter/ww8/ww8glsy.cxx +++ b/sw/source/filter/ww8/ww8glsy.cxx @@ -71,10 +71,10 @@ bool WW8Glossary::HasBareGraphicEnd(SwDoc *pDoc,SwNodeIndex const &rIdx) ((RndStdIds::FLY_AT_PARA == rAnchor.GetAnchorId()) || (RndStdIds::FLY_AT_CHAR == rAnchor.GetAnchorId())) && rIdx == pAPos->nNode.GetIndex() ) - { - bRet=true; - break; - } + { + bRet=true; + break; + } } return bRet; } diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx index 5d96a44e9196..ad56049a6e97 100644 --- a/sw/source/filter/ww8/ww8par2.cxx +++ b/sw/source/filter/ww8/ww8par2.cxx @@ -2699,7 +2699,7 @@ void WW8TabDesc::MergeCells() // (that can be a newly created or another group) UpdateTableMergeGroup( rCell, pActMGroup, m_pTabBox, i ); } - } + } } } diff --git a/sw/source/filter/ww8/ww8par6.cxx b/sw/source/filter/ww8/ww8par6.cxx index b5a5623fd22a..6dc0a5e5df5b 100644 --- a/sw/source/filter/ww8/ww8par6.cxx +++ b/sw/source/filter/ww8/ww8par6.cxx @@ -3063,7 +3063,7 @@ void SwWW8ImplReader::Read_BoldUsw( sal_uInt16 nId, const sal_uInt8* pData, shor pSI->m_n81Flags |= nMask; // set flag else pSI->m_n81Flags &= ~nMask; // delete flag - } + } } else { diff --git a/sw/source/filter/xml/xmliteme.cxx b/sw/source/filter/xml/xmliteme.cxx index 61a8205064ff..447abab52b67 100644 --- a/sw/source/filter/xml/xmliteme.cxx +++ b/sw/source/filter/xml/xmliteme.cxx @@ -129,8 +129,8 @@ void SwXMLTableItemMapper_Impl::handleSpecialItem( AddAttribute( rEntry.nNameSpace, rEntry.eLocalName, sValue, rNamespaceMap, rAttrList ); } - } - } + } + } } break; diff --git a/sw/source/filter/xml/xmlithlp.cxx b/sw/source/filter/xml/xmlithlp.cxx index 57f845e206f8..16e2a1128b08 100644 --- a/sw/source/filter/xml/xmlithlp.cxx +++ b/sw/source/filter/xml/xmlithlp.cxx @@ -164,7 +164,7 @@ bool sw_frmitems_setXMLBorder( std::unique_ptr<SvxBorderLine>& rpLine, ( bHasStyle && ((table::BorderLineStyle::SOLID == nStyle && rpLine->GetDistance()) || (table::BorderLineStyle::DOUBLE == nStyle && !rpLine->GetDistance())) ) ) - { + { bool bDouble = (bHasWidth && table::BorderLineStyle::DOUBLE == nStyle ) || rpLine->GetDistance(); @@ -190,7 +190,7 @@ bool sw_frmitems_setXMLBorder( std::unique_ptr<SvxBorderLine>& rpLine, } } sw_frmitems_setXMLBorderStyle( *rpLine, nStyle ); - } + } // set color if( bHasColor ) diff --git a/sw/source/ui/dbui/addresslistdialog.cxx b/sw/source/ui/dbui/addresslistdialog.cxx index f30a39a26080..aac1602f3968 100644 --- a/sw/source/ui/dbui/addresslistdialog.cxx +++ b/sw/source/ui/dbui/addresslistdialog.cxx @@ -310,12 +310,12 @@ IMPL_LINK_NOARG(SwAddressListDialog, RemoveHdl_Impl, weld::Button&, void) m_xListLB->remove(nEntry); // If this was the last item, disable the Remove & Edit buttons and enable Create if (m_xListLB->n_children() < 1 ) - { + { m_xRemovePB->set_sensitive(false); m_xEditPB->set_sensitive(false); m_xFilterPB->set_sensitive(false); m_xCreateListPB->set_sensitive(true); - } + } } diff --git a/sw/source/ui/vba/vbafont.cxx b/sw/source/ui/vba/vbafont.cxx index 1b16c07bd2b3..79642b3109f4 100644 --- a/sw/source/ui/vba/vbafont.cxx +++ b/sw/source/ui/vba/vbafont.cxx @@ -158,7 +158,7 @@ SwVbaFont::getColorIndex() sal_Int32 nElems = mxPalette->getCount(); sal_Int32 nIndex = 0; for ( sal_Int32 count=0; count<nElems; ++count ) - { + { sal_Int32 nPaletteColor = 0; mxPalette->getByIndex( count ) >>= nPaletteColor; if ( nPaletteColor == nColor ) diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx index 475388d2134e..9aad1ea7ed64 100644 --- a/sw/source/uibase/dbui/dbmgr.cxx +++ b/sw/source/uibase/dbui/dbmgr.cxx @@ -2437,15 +2437,15 @@ SwDSParam* SwDBManager::FindDSData(const SwDBData& rData, bool bCreate) rData.sCommand == pParam->sCommand && (rData.nCommandType == -1 || rData.nCommandType == pParam->nCommandType || (bCreate && pParam->nCommandType == -1))) - { - // calls from the calculator may add a connection with an invalid commandtype - //later added "real" data base connections have to re-use the already available - //DSData and set the correct CommandType - if(bCreate && pParam->nCommandType == -1) - pParam->nCommandType = rData.nCommandType; - pFound = pParam; - break; - } + { + // calls from the calculator may add a connection with an invalid commandtype + //later added "real" data base connections have to re-use the already available + //DSData and set the correct CommandType + if(bCreate && pParam->nCommandType == -1) + pParam->nCommandType = rData.nCommandType; + pFound = pParam; + break; + } } if(bCreate && !pFound) { diff --git a/sw/source/uibase/dochdl/swdtflvr.cxx b/sw/source/uibase/dochdl/swdtflvr.cxx index 772889bf06f7..ff7ee5e872a3 100644 --- a/sw/source/uibase/dochdl/swdtflvr.cxx +++ b/sw/source/uibase/dochdl/swdtflvr.cxx @@ -2291,7 +2291,7 @@ bool SwTransferable::PasteOLE( TransferableDataHelper& rData, SwWrtShell& rSh, else { if( rData.HasFormat( SotClipboardFormatId::OBJECTDESCRIPTOR_OLE ) && rData.GetTransferableObjectDescriptor( nFormat, aObjDesc ) ) - { + { xStrm = rData.GetInputStream(SotClipboardFormatId::EMBED_SOURCE_OLE, OUString()); if (!xStrm.is()) xStrm = rData.GetInputStream(SotClipboardFormatId::EMBEDDED_OBJ_OLE, OUString()); diff --git a/sw/source/uibase/inc/usrpref.hxx b/sw/source/uibase/inc/usrpref.hxx index e93d6a050d06..1464c90bce3c 100644 --- a/sw/source/uibase/inc/usrpref.hxx +++ b/sw/source/uibase/inc/usrpref.hxx @@ -177,7 +177,7 @@ public: if(bSet && m_eFieldUpdateFlags == AUTOUPD_OFF) { m_eFieldUpdateFlags = AUTOUPD_FIELD_ONLY; - } + } else if(!bSet) { m_eFieldUpdateFlags = AUTOUPD_OFF; @@ -197,11 +197,11 @@ public: if(bSet) { m_eFieldUpdateFlags = AUTOUPD_FIELD_AND_CHARTS; - } - else if(m_eFieldUpdateFlags == AUTOUPD_FIELD_AND_CHARTS) - { + } + else if(m_eFieldUpdateFlags == AUTOUPD_FIELD_AND_CHARTS) + { m_eFieldUpdateFlags = AUTOUPD_FIELD_ONLY; - } + } }; bool IsUpdateCharts()const {return m_eFieldUpdateFlags == AUTOUPD_FIELD_AND_CHARTS; } diff --git a/sw/source/uibase/shells/textsh1.cxx b/sw/source/uibase/shells/textsh1.cxx index 0c11a9395a40..f500f618c48a 100644 --- a/sw/source/uibase/shells/textsh1.cxx +++ b/sw/source/uibase/shells/textsh1.cxx @@ -1889,7 +1889,7 @@ void SwTextShell::GetState( SfxItemSet &rSet ) } else bIsPhysical = false; - } + } } } diff --git a/sw/source/uibase/uitest/uiobject.cxx b/sw/source/uibase/uitest/uiobject.cxx index c120bdd778f7..7a19b4c8d88e 100644 --- a/sw/source/uibase/uitest/uiobject.cxx +++ b/sw/source/uibase/uitest/uiobject.cxx @@ -172,12 +172,12 @@ void CommentUIObject::execute(const OUString& rAction, { if (rParameters.find("FROM") != rParameters.end() && rParameters.find("TO") != rParameters.end()) - { + { tools::Long nMin = rParameters.find("FROM")->second.toInt32(); tools::Long nMax = rParameters.find("TO")->second.toInt32(); ESelection aNewSelection( 0 , nMin, mxCommentUIObject->GetOutliner()->GetParagraphCount()-1, nMax ); mxCommentUIObject->GetOutlinerView()->SetSelection( aNewSelection ); - } + } } else if (rAction == "LEAVE") { diff --git a/sw/source/uibase/wrtsh/wrtsh1.cxx b/sw/source/uibase/wrtsh/wrtsh1.cxx index 4eb96467fc80..3be1be85b1f3 100644 --- a/sw/source/uibase/wrtsh/wrtsh1.cxx +++ b/sw/source/uibase/wrtsh/wrtsh1.cxx @@ -196,7 +196,7 @@ void SwWrtShell::InsertByWord( const OUString & rStr) bool bDelim = GetAppCharClass().isLetterNumeric( rStr, 0 ); sal_Int32 nPos = 0, nStt = 0; for( ; nPos < rStr.getLength(); nPos++ ) - { + { bool bTmpDelim = GetAppCharClass().isLetterNumeric( rStr, nPos ); if( bTmpDelim != bDelim ) { |