summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-05-22 15:55:38 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-05-30 08:50:31 +0200
commit2ccde70d60d3a5074faf49260e8fe0ccdb91ff26 (patch)
tree82555c2aac7ca37c30e1084a7a8069c71fc11fbc /sw
parent61ff1d919e317947c769e61eeda7f1bb8132f273 (diff)
teach redundantcast plugin about functional casts
Change-Id: Iac8ccd17d9e46ebb2cb55db7adb06c469bbd4ea0 Reviewed-on: https://gerrit.libreoffice.org/37910 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sw')
-rw-r--r--sw/qa/extras/tiledrendering/tiledrendering.cxx2
-rw-r--r--sw/source/core/crsr/bookmrk.cxx2
-rw-r--r--sw/source/core/draw/dcontact.cxx2
-rw-r--r--sw/source/core/fields/authfld.cxx2
-rw-r--r--sw/source/core/layout/anchoredobject.cxx2
-rw-r--r--sw/source/core/layout/fly.cxx4
-rw-r--r--sw/source/core/layout/flylay.cxx2
-rw-r--r--sw/source/core/layout/paintfrm.cxx2
-rw-r--r--sw/source/core/text/frmcrsr.cxx2
-rw-r--r--sw/source/core/text/itrform2.cxx2
-rw-r--r--sw/source/core/txtnode/fntcache.cxx2
-rw-r--r--sw/source/filter/html/htmlform.cxx4
-rw-r--r--sw/source/filter/ww8/docxattributeoutput.cxx8
-rw-r--r--sw/source/filter/ww8/docxexport.cxx2
-rw-r--r--sw/source/filter/ww8/docxsdrexport.cxx2
-rw-r--r--sw/source/filter/ww8/rtfattributeoutput.cxx4
-rw-r--r--sw/source/filter/ww8/wrtww8.cxx2
-rw-r--r--sw/source/ui/frmdlg/column.cxx2
-rw-r--r--sw/source/ui/misc/pgfnote.cxx2
-rw-r--r--sw/source/ui/vba/vbacolumn.cxx2
-rw-r--r--sw/source/uibase/app/docsh2.cxx4
-rw-r--r--sw/source/uibase/dochdl/swdtflvr.cxx2
-rw-r--r--sw/source/uibase/uiview/viewmdi.cxx4
-rw-r--r--sw/source/uibase/uiview/viewsrch.cxx6
-rw-r--r--sw/source/uibase/uiview/viewtab.cxx8
25 files changed, 38 insertions, 38 deletions
diff --git a/sw/qa/extras/tiledrendering/tiledrendering.cxx b/sw/qa/extras/tiledrendering/tiledrendering.cxx
index d876736f8076..22d010796da9 100644
--- a/sw/qa/extras/tiledrendering/tiledrendering.cxx
+++ b/sw/qa/extras/tiledrendering/tiledrendering.cxx
@@ -362,7 +362,7 @@ void SwTiledRenderingTest::testGetTextSelection()
CPPUNIT_ASSERT_EQUAL(OString("Hello"), pXTextDocument->getTextSelection("text/plain;charset=utf-8", aUsedFormat));
// Make sure we produce something for HTML.
- CPPUNIT_ASSERT(!OString(pXTextDocument->getTextSelection("text/html", aUsedFormat)).isEmpty());
+ CPPUNIT_ASSERT(!pXTextDocument->getTextSelection("text/html", aUsedFormat).isEmpty());
// Now select some shape text and check again.
SdrPage* pPage = pWrtShell->GetDoc()->getIDocumentDrawModelAccess().GetDrawModel()->GetPage(0);
diff --git a/sw/source/core/crsr/bookmrk.cxx b/sw/source/core/crsr/bookmrk.cxx
index 09992bf5df48..e0f1d8e12ed0 100644
--- a/sw/source/core/crsr/bookmrk.cxx
+++ b/sw/source/core/crsr/bookmrk.cxx
@@ -323,7 +323,7 @@ namespace sw { namespace mark
{
SwDoc *const pDoc( GetMarkPos().GetDoc() );
assert(pDoc);
- return !pDoc->IsInHeaderFooter( SwNodeIndex(GetMarkPos().nNode) );
+ return !pDoc->IsInHeaderFooter( GetMarkPos().nNode );
}
uno::Reference< rdf::XMetadatable > Bookmark::MakeUnoObject()
diff --git a/sw/source/core/draw/dcontact.cxx b/sw/source/core/draw/dcontact.cxx
index 9bb337506f90..5c620cafc4d3 100644
--- a/sw/source/core/draw/dcontact.cxx
+++ b/sw/source/core/draw/dcontact.cxx
@@ -2475,7 +2475,7 @@ Point SwDrawVirtObj::GetSnapPoint(sal_uInt32 i) const
Point SwDrawVirtObj::GetPoint(sal_uInt32 i) const
{
- return Point(rRefObj.GetPoint(i) + GetOffset());
+ return rRefObj.GetPoint(i) + GetOffset();
}
void SwDrawVirtObj::NbcSetPoint(const Point& rPnt, sal_uInt32 i)
diff --git a/sw/source/core/fields/authfld.cxx b/sw/source/core/fields/authfld.cxx
index 6b458fe418c7..498a5a1d44d9 100644
--- a/sw/source/core/fields/authfld.cxx
+++ b/sw/source/core/fields/authfld.cxx
@@ -493,7 +493,7 @@ void SwAuthorityFieldType::SetSortKeys(sal_uInt16 nKeyCount, SwTOXSortKey aKeys[
m_SortKeyArr.clear();
for(sal_uInt16 i = 0; i < nKeyCount; i++)
if(aKeys[i].eField < AUTH_FIELD_END)
- m_SortKeyArr.push_back(SwTOXSortKey(aKeys[i]));
+ m_SortKeyArr.push_back(aKeys[i]);
}
SwAuthorityField::SwAuthorityField( SwAuthorityFieldType* pInitType,
diff --git a/sw/source/core/layout/anchoredobject.cxx b/sw/source/core/layout/anchoredobject.cxx
index 4b79a357771f..d0c7f320dfc7 100644
--- a/sw/source/core/layout/anchoredobject.cxx
+++ b/sw/source/core/layout/anchoredobject.cxx
@@ -575,7 +575,7 @@ const SwRect& SwAnchoredObject::GetObjRectWithSpaces() const
const SvxLRSpaceItem& rLR = rFormat.GetLRSpace();
{
maObjRectWithSpaces.Top ( std::max( maObjRectWithSpaces.Top() - long(rUL.GetUpper()), 0L ));
- maObjRectWithSpaces.Left( std::max( maObjRectWithSpaces.Left()- long(rLR.GetLeft()), 0L ));
+ maObjRectWithSpaces.Left( std::max( maObjRectWithSpaces.Left()- rLR.GetLeft(), 0L ));
maObjRectWithSpaces.SSize().Height() += rUL.GetLower();
maObjRectWithSpaces.SSize().Width() += rLR.GetRight();
}
diff --git a/sw/source/core/layout/fly.cxx b/sw/source/core/layout/fly.cxx
index df8f3a6f84fe..8ad675b77590 100644
--- a/sw/source/core/layout/fly.cxx
+++ b/sw/source/core/layout/fly.cxx
@@ -745,7 +745,7 @@ void SwFlyFrame::UpdateAttr_( const SfxPoolItem *pOld, const SfxPoolItem *pNew,
aOld.Top( std::max( aOld.Top() - long(rUL.GetUpper()), 0L ) );
aOld.SSize().Height()+= rUL.GetLower();
const SvxLRSpaceItem &rLR = static_cast<const SwFormatChg*>(pOld)->pChangedFormat->GetLRSpace();
- aOld.Left ( std::max( aOld.Left() - long(rLR.GetLeft()), 0L ) );
+ aOld.Left ( std::max( aOld.Left() - rLR.GetLeft(), 0L ) );
aOld.SSize().Width() += rLR.GetRight();
aNew.Union( aOld );
NotifyBackground( FindPageFrame(), aNew, PREP_CLEAR );
@@ -850,7 +850,7 @@ void SwFlyFrame::UpdateAttr_( const SfxPoolItem *pOld, const SfxPoolItem *pNew,
else
{
const SvxLRSpaceItem &rLR = *static_cast<const SvxLRSpaceItem*>(pNew);
- aOld.Left ( std::max( aOld.Left() - long(rLR.GetLeft()), 0L ) );
+ aOld.Left ( std::max( aOld.Left() - rLR.GetLeft(), 0L ) );
aOld.SSize().Width() += rLR.GetRight();
}
}
diff --git a/sw/source/core/layout/flylay.cxx b/sw/source/core/layout/flylay.cxx
index 59f9e82fd78f..47b10ca812d2 100644
--- a/sw/source/core/layout/flylay.cxx
+++ b/sw/source/core/layout/flylay.cxx
@@ -419,7 +419,7 @@ void SwFlyFreeFrame::CheckClip( const SwFormatFrameSize &rSz )
// otherwise we'll end up with unwanted side-effects/oscillations
const long nPrtHeightDiff = Frame().Height() - Prt().Height();
const long nPrtWidthDiff = Frame().Width() - Prt().Width();
- maUnclippedFrame = SwRect( Frame() );
+ maUnclippedFrame = Frame();
Frame().Height( aFrameRect.Height() );
Frame().Width ( std::max( long(MINLAY), aFrameRect.Width() ) );
if ( Lower() && Lower()->IsColumnFrame() )
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx
index 008e26f9efef..515e0d523bd9 100644
--- a/sw/source/core/layout/paintfrm.cxx
+++ b/sw/source/core/layout/paintfrm.cxx
@@ -5107,7 +5107,7 @@ void PaintCharacterBorder(
if( aShadow.GetLocation() != SvxShadowLocation::NONE )
{
- lcl_PaintShadow( SwRect(aAlignedRect), aAlignedRect, aShadow,
+ lcl_PaintShadow( aAlignedRect, aAlignedRect, aShadow,
false, bTop, bBottom, bLeft, bRight, gProp);
}
}
diff --git a/sw/source/core/text/frmcrsr.cxx b/sw/source/core/text/frmcrsr.cxx
index 18c26d55c591..2b51799c566c 100644
--- a/sw/source/core/text/frmcrsr.cxx
+++ b/sw/source/core/text/frmcrsr.cxx
@@ -1402,7 +1402,7 @@ void SwTextFrame::FillCursorPos( SwFillData& rFill ) const
nFirst = nFirst - nDist;
else
nFirst = 0;
- nDist = std::max( nDist, long( GetLineSpace() ) );
+ nDist = std::max( nDist, GetLineSpace() );
nDist += nLineHeight;
nDiff -= nFirst;
diff --git a/sw/source/core/text/itrform2.cxx b/sw/source/core/text/itrform2.cxx
index bd1890620c4e..42245d3a5e7a 100644
--- a/sw/source/core/text/itrform2.cxx
+++ b/sw/source/core/text/itrform2.cxx
@@ -1774,7 +1774,7 @@ void SwTextFormatter::CalcRealHeight( bool bNewLine )
break;
case SvxLineSpaceRule::Min:
{
- if( nLineHeight < sal_uInt16( pSpace->GetLineHeight() ) )
+ if( nLineHeight < pSpace->GetLineHeight() )
nLineHeight = pSpace->GetLineHeight();
break;
}
diff --git a/sw/source/core/txtnode/fntcache.cxx b/sw/source/core/txtnode/fntcache.cxx
index 8617a3b80db4..8f02ce2fe8b8 100644
--- a/sw/source/core/txtnode/fntcache.cxx
+++ b/sw/source/core/txtnode/fntcache.cxx
@@ -1985,7 +1985,7 @@ Size SwFntObj::GetTextSize( SwDrawTextInfo& rInf )
}
if ( rInf.GetKern() && nLn )
- aTextSize.Width() += ( nLn - 1 ) * long( rInf.GetKern() );
+ aTextSize.Width() += ( nLn - 1 ) * rInf.GetKern();
OSL_ENSURE( !rInf.GetShell() ||
( USHRT_MAX != GetGuessedLeading() && USHRT_MAX != GetExternalLeading() ),
diff --git a/sw/source/filter/html/htmlform.cxx b/sw/source/filter/html/htmlform.cxx
index fb7cf356e1d7..30e4282858db 100644
--- a/sw/source/filter/html/htmlform.cxx
+++ b/sw/source/filter/html/htmlform.cxx
@@ -1337,11 +1337,11 @@ void SwHTMLParser::NewForm( bool bAppend )
xFormPropSet->setPropertyValue("TargetURL",
aTmp );
- aTmp <<= FormSubmitMethod(nMethod);
+ aTmp <<= nMethod;
xFormPropSet->setPropertyValue("SubmitMethod",
aTmp );
- aTmp <<= FormSubmitEncoding(nEncType);
+ aTmp <<= nEncType;
xFormPropSet->setPropertyValue("SubmitEncoding", aTmp );
if( !sTarget.isEmpty() )
diff --git a/sw/source/filter/ww8/docxattributeoutput.cxx b/sw/source/filter/ww8/docxattributeoutput.cxx
index 8e97812d3a20..d7dbd1d575bf 100644
--- a/sw/source/filter/ww8/docxattributeoutput.cxx
+++ b/sw/source/filter/ww8/docxattributeoutput.cxx
@@ -8016,16 +8016,16 @@ void DocxAttributeOutput::FormatBox( const SvxBoxItem& rBox )
// otherwise - 'right' is checked if it is default and if it is non-default - all the values except for 'bottom' will be written
// and so on.
OStringBuffer aInset;
- if(!aInset.isEmpty() || fDistanceBottomInch != double(0.05))
+ if(!aInset.isEmpty() || fDistanceBottomInch != 0.05)
aInset.insert(0, "," + OString::number(fDistanceBottomInch) + "in");
- if(!aInset.isEmpty() || fDistanceRightInch != double(0.1))
+ if(!aInset.isEmpty() || fDistanceRightInch != 0.1)
aInset.insert(0, "," + OString::number(fDistanceRightInch) + "in");
- if(!aInset.isEmpty() || fDistanceTopInch != double(0.05))
+ if(!aInset.isEmpty() || fDistanceTopInch != 0.05)
aInset.insert(0, "," + OString::number(fDistanceTopInch) + "in");
- if(!aInset.isEmpty() || fDistanceLeftInch != double(0.1))
+ if(!aInset.isEmpty() || fDistanceLeftInch != 0.1)
aInset.insert(0, OString::number(fDistanceLeftInch) + "in");
if (!aInset.isEmpty())
diff --git a/sw/source/filter/ww8/docxexport.cxx b/sw/source/filter/ww8/docxexport.cxx
index 69cd9444a85d..e06585d4ee5a 100644
--- a/sw/source/filter/ww8/docxexport.cxx
+++ b/sw/source/filter/ww8/docxexport.cxx
@@ -1077,7 +1077,7 @@ void DocxExport::WriteGlossary()
gId = gId.copy(3); //"rId" only save the numeric value
PropertySet aProps(xOutputStream);
- aProps.setAnyProperty( PROP_RelId, uno::makeAny( sal_Int32( gId.toInt32() )));
+ aProps.setAnyProperty( PROP_RelId, uno::makeAny( gId.toInt32() ));
m_pFilter->addRelation( xOutputStream, gType, gTarget);
uno::Reference< xml::sax::XSAXSerializable > gserializer( xDom, uno::UNO_QUERY );
writer->setOutputStream(GetFilter().openFragmentStream( "word/glossary/" + gTarget, contentType ) );
diff --git a/sw/source/filter/ww8/docxsdrexport.cxx b/sw/source/filter/ww8/docxsdrexport.cxx
index dd44481799e8..ee3b0ae1476c 100644
--- a/sw/source/filter/ww8/docxsdrexport.cxx
+++ b/sw/source/filter/ww8/docxsdrexport.cxx
@@ -1069,7 +1069,7 @@ void DocxSdrExport::writeDiagramRels(const uno::Sequence< uno::Sequence< uno::An
sFragment += sGrabBagProperyName + OUString::number(nAnchorId) + "_" + OUString::number(j) + sExtension;
PropertySet aProps(xOutStream);
- aProps.setAnyProperty(PROP_RelId, uno::makeAny(sal_Int32(sRelId.toInt32())));
+ aProps.setAnyProperty(PROP_RelId, uno::makeAny(sRelId.toInt32()));
m_pImpl->m_rExport.GetFilter().addRelation(xOutStream, sType, sFragment);
diff --git a/sw/source/filter/ww8/rtfattributeoutput.cxx b/sw/source/filter/ww8/rtfattributeoutput.cxx
index 82ab2d2509ac..8a6dbdbe113b 100644
--- a/sw/source/filter/ww8/rtfattributeoutput.cxx
+++ b/sw/source/filter/ww8/rtfattributeoutput.cxx
@@ -1719,9 +1719,9 @@ void lcl_TextFrameShadow(std::vector< std::pair<OString, OString> >& rFlyPropert
break;
}
if (!aOffsetX.isEmpty())
- rFlyProperties.push_back(std::make_pair<OString, OString>("shadowOffsetX", OString(aOffsetX)));
+ rFlyProperties.emplace_back( "shadowOffsetX", aOffsetX );
if (!aOffsetY.isEmpty())
- rFlyProperties.push_back(std::make_pair<OString, OString>("shadowOffsetY", OString(aOffsetY)));
+ rFlyProperties.emplace_back( "shadowOffsetY", aOffsetY );
}
void lcl_TextFrameRelativeSize(std::vector< std::pair<OString, OString> >& rFlyProperties, const SwFrameFormat& rFrameFormat)
diff --git a/sw/source/filter/ww8/wrtww8.cxx b/sw/source/filter/ww8/wrtww8.cxx
index 8315e3d7af62..35433cd7d119 100644
--- a/sw/source/filter/ww8/wrtww8.cxx
+++ b/sw/source/filter/ww8/wrtww8.cxx
@@ -2124,7 +2124,7 @@ void WW8AttributeOutput::TableVerticalCell( ww8::WW8TableNodeInfoInner::Pointer_
if ( SvxFrameDirection::Vertical_RL_TB == m_rWW8Export.TrueFrameDirection( *pFrameFormat ) )
{
m_rWW8Export.InsUInt16( NS_sprm::sprmTTextFlow );
- m_rWW8Export.pO->push_back( sal_uInt8(n) ); //start range
+ m_rWW8Export.pO->push_back( n ); //start range
m_rWW8Export.pO->push_back( sal_uInt8(n + 1) ); //end range
m_rWW8Export.InsUInt16( 5 ); //Equals vertical writing
}
diff --git a/sw/source/ui/frmdlg/column.cxx b/sw/source/ui/frmdlg/column.cxx
index 61ffc364c731..473cea4543b6 100644
--- a/sw/source/ui/frmdlg/column.cxx
+++ b/sw/source/ui/frmdlg/column.cxx
@@ -733,7 +733,7 @@ IMPL_LINK_NOARG( SwColumnPage, UpdateColMgr, Edit&, void )
else
{
m_pColMgr->SetLineWidthAndColor(
- SvxBorderLineStyle( m_pLineTypeDLB->GetSelectEntryStyle( ) ),
+ m_pLineTypeDLB->GetSelectEntryStyle(),
nLineWidth,
m_pLineColorDLB->GetSelectEntryColor() );
m_pColMgr->SetAdjust( SwColLineAdj(
diff --git a/sw/source/ui/misc/pgfnote.cxx b/sw/source/ui/misc/pgfnote.cxx
index 65f5829dc936..f23964aa1378 100644
--- a/sw/source/ui/misc/pgfnote.cxx
+++ b/sw/source/ui/misc/pgfnote.cxx
@@ -253,7 +253,7 @@ bool SwFootNotePage::FillItemSet(SfxItemSet *rSet)
m_pLineDistEdit->Denormalize(m_pLineDistEdit->GetValue(FUNIT_TWIP))));
// Separator style
- rFootnoteInfo.SetLineStyle( SvxBorderLineStyle( m_pLineTypeBox->GetSelectEntryStyle() ) );
+ rFootnoteInfo.SetLineStyle( m_pLineTypeBox->GetSelectEntryStyle() );
// Separator width
long nWidth = static_cast<long>(MetricField::ConvertDoubleValue(
diff --git a/sw/source/ui/vba/vbacolumn.cxx b/sw/source/ui/vba/vbacolumn.cxx
index ffa15ce28181..89ef096d97c1 100644
--- a/sw/source/ui/vba/vbacolumn.cxx
+++ b/sw/source/ui/vba/vbacolumn.cxx
@@ -67,7 +67,7 @@ void SwVbaColumn::SelectColumn( const uno::Reference< frame::XModel >& xModel, c
aRangeName.append(sStartCol).append(sal_Int32( 1 ) );
OUString sEndCol = SwVbaTableHelper::getColumnStr( nEndColumn );
sal_Int32 nRowCount = xTextTable->getRows()->getCount();
- aRangeName.append(':').append( sEndCol ).append( sal_Int32( nRowCount ) );
+ aRangeName.append(':').append( sEndCol ).append( nRowCount );
uno::Reference< table::XCellRange > xCellRange( xTextTable, uno::UNO_QUERY_THROW );
OUString sSelRange = aRangeName.makeStringAndClear();
diff --git a/sw/source/uibase/app/docsh2.cxx b/sw/source/uibase/app/docsh2.cxx
index 4cb22e077ef8..f5c6316ddbac 100644
--- a/sw/source/uibase/app/docsh2.cxx
+++ b/sw/source/uibase/app/docsh2.cxx
@@ -743,7 +743,7 @@ void SwDocShell::Execute(SfxRequest& rReq)
}
}
else
- ErrorHandler::HandleError(ErrCode( eErr ));
+ ErrorHandler::HandleError( eErr );
}
else
{
@@ -820,7 +820,7 @@ void SwDocShell::Execute(SfxRequest& rReq)
}
}
else
- ErrorHandler::HandleError(ErrCode( eErr ));
+ ErrorHandler::HandleError( eErr );
}
break;
case SID_SPELLCHECKER_CHANGED:
diff --git a/sw/source/uibase/dochdl/swdtflvr.cxx b/sw/source/uibase/dochdl/swdtflvr.cxx
index 4615824bccc3..a21b3648dd72 100644
--- a/sw/source/uibase/dochdl/swdtflvr.cxx
+++ b/sw/source/uibase/dochdl/swdtflvr.cxx
@@ -1883,7 +1883,7 @@ bool SwTransferable::PasteOLE( TransferableDataHelper& rData, SwWrtShell& rSh,
}
else if( aObjDesc.maSize.Width() && aObjDesc.maSize.Height() )
{
- aSize = Size( aObjDesc.maSize ); //always 100TH_MM
+ aSize = aObjDesc.maSize; //always 100TH_MM
MapUnit aUnit = VCLUnoHelper::UnoEmbed2VCLMapUnit( xObj->getMapUnit( aObjDesc.mnViewAspect ) );
aSize = OutputDevice::LogicToLogic( aSize, MapUnit::Map100thMM, aUnit );
awt::Size aSz;
diff --git a/sw/source/uibase/uiview/viewmdi.cxx b/sw/source/uibase/uiview/viewmdi.cxx
index e8dd1a8ce4ea..460dce33e3b5 100644
--- a/sw/source/uibase/uiview/viewmdi.cxx
+++ b/sw/source/uibase/uiview/viewmdi.cxx
@@ -108,14 +108,14 @@ void SwView::SetZoom_( const Size &rEditSize, SvxZoomType eZoomType,
if( UseOnPage::Mirror == rDesc.GetUseOn() ) // mirrored pages
{
const SvxLRSpaceItem &rLeftLRSpace = rDesc.GetLeft().GetLRSpace();
- aPageSize.Width() += std::abs( long(rLeftLRSpace.GetLeft()) - long(rLRSpace.GetLeft()) );
+ aPageSize.Width() += std::abs( rLeftLRSpace.GetLeft() - rLRSpace.GetLeft() );
}
if( SvxZoomType::OPTIMAL == eZoomType )
{
if (!pPostItMgr->HasNotes() || !pPostItMgr->ShowNotes())
aPageSize.Width() -= ( rLRSpace.GetLeft() + rLRSpace.GetRight() + nLeftOfst * 2 );
- lLeftMargin = long(rLRSpace.GetLeft()) + DOCUMENTBORDER + nLeftOfst;
+ lLeftMargin = rLRSpace.GetLeft() + DOCUMENTBORDER + nLeftOfst;
nFac = aWindowSize.Width() * 100 / aPageSize.Width();
}
else if(SvxZoomType::WHOLEPAGE == eZoomType || SvxZoomType::PAGEWIDTH == eZoomType )
diff --git a/sw/source/uibase/uiview/viewsrch.cxx b/sw/source/uibase/uiview/viewsrch.cxx
index 3b3ff0ba371e..c94038539893 100644
--- a/sw/source/uibase/uiview/viewsrch.cxx
+++ b/sw/source/uibase/uiview/viewsrch.cxx
@@ -846,7 +846,7 @@ sal_uLong SwView::FUNC_Search( const SwSearchOptions& rOptions )
!m_pSrchItem->GetPattern(),
rOptions.eStart,
rOptions.eEnd,
- FindRanges(eRanges),
+ eRanges,
!m_pSrchItem->GetSearchString().isEmpty() ? &aSearchOpt : nullptr,
pReplSet );
}
@@ -857,7 +857,7 @@ sal_uLong SwView::FUNC_Search( const SwSearchOptions& rOptions )
nFound = m_pWrtShell->SearchTempl( m_pSrchItem->GetSearchString(),
rOptions.eStart,
rOptions.eEnd,
- FindRanges(eRanges),
+ eRanges,
bDoReplace ? &sRplStr : nullptr );
}
else
@@ -866,7 +866,7 @@ sal_uLong SwView::FUNC_Search( const SwSearchOptions& rOptions )
nFound = m_pWrtShell->SearchPattern(aSearchOpt, m_pSrchItem->GetNotes(),
rOptions.eStart,
rOptions.eEnd,
- FindRanges(eRanges),
+ eRanges,
bDoReplace );
}
m_pWrtShell->EndSelect();
diff --git a/sw/source/uibase/uiview/viewtab.cxx b/sw/source/uibase/uiview/viewtab.cxx
index 1e85f5fca224..7eff56c3f7e0 100644
--- a/sw/source/uibase/uiview/viewtab.cxx
+++ b/sw/source/uibase/uiview/viewtab.cxx
@@ -1127,7 +1127,7 @@ void SwView::ExecTabWin( SfxRequest& rReq )
{
XFillColorItem aColorItem( static_cast<const XFillColorItem&>(pReqArgs->Get( XATTR_FILLCOLOR )) );
rMaster.SetFormatAttr( XFillStyleItem( drawing::FillStyle_SOLID ) );
- rMaster.SetFormatAttr( XFillColorItem( aColorItem ));
+ rMaster.SetFormatAttr( aColorItem );
}
break;
@@ -1135,7 +1135,7 @@ void SwView::ExecTabWin( SfxRequest& rReq )
{
XFillGradientItem aGradientItem( static_cast<const XFillGradientItem&>(pReqArgs->Get( XATTR_FILLGRADIENT )) );
rMaster.SetFormatAttr( XFillStyleItem( drawing::FillStyle_GRADIENT ) );
- rMaster.SetFormatAttr( XFillGradientItem( aGradientItem ) );
+ rMaster.SetFormatAttr( aGradientItem );
}
break;
@@ -1143,7 +1143,7 @@ void SwView::ExecTabWin( SfxRequest& rReq )
{
XFillHatchItem aHatchItem( static_cast<const XFillHatchItem&>(pReqArgs->Get( XATTR_FILLHATCH )) );
rMaster.SetFormatAttr( XFillStyleItem( drawing::FillStyle_HATCH ) );
- rMaster.SetFormatAttr( XFillHatchItem( aHatchItem ));
+ rMaster.SetFormatAttr( aHatchItem );
}
break;
@@ -1151,7 +1151,7 @@ void SwView::ExecTabWin( SfxRequest& rReq )
{
XFillBitmapItem aBitmapItem( static_cast<const XFillBitmapItem&>(pReqArgs->Get( XATTR_FILLBITMAP )) );
rMaster.SetFormatAttr( XFillStyleItem( drawing::FillStyle_BITMAP ) );
- rMaster.SetFormatAttr( XFillBitmapItem( aBitmapItem ));
+ rMaster.SetFormatAttr( aBitmapItem );
}
break;