summaryrefslogtreecommitdiff
path: root/sc/source
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-04-25 18:56:17 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-04-27 10:10:52 +0200
commitf3049f68584811bb897873f35e0c302898af2d31 (patch)
treeb77f8bee3f733b8f2565a64276e33387576a26ac /sc/source
parent28fc0962b10519ab84654d189d2ad0cca8f84f95 (diff)
loplugin:constantparam
Change-Id: I966dcf87be021520e7cc394338b9c0574bb8afee Reviewed-on: https://gerrit.libreoffice.org/53541 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source')
-rw-r--r--sc/source/core/data/postit.cxx4
-rw-r--r--sc/source/filter/excel/xiescher.cxx3
-rw-r--r--sc/source/filter/xml/xmlcelli.cxx2
-rw-r--r--sc/source/ui/attrdlg/scdlgfact.cxx2
-rw-r--r--sc/source/ui/inc/delcodlg.hxx2
-rw-r--r--sc/source/ui/miscdlgs/delcodlg.cxx8
6 files changed, 7 insertions, 14 deletions
diff --git a/sc/source/core/data/postit.cxx b/sc/source/core/data/postit.cxx
index 50d416077d89..7b51b97431bd 100644
--- a/sc/source/core/data/postit.cxx
+++ b/sc/source/core/data/postit.cxx
@@ -1242,7 +1242,7 @@ ScPostIt* ScNoteUtil::CreateNoteFromCaption(
ScPostIt* ScNoteUtil::CreateNoteFromObjectData(
ScDocument& rDoc, const ScAddress& rPos, std::unique_ptr<SfxItemSet> pItemSet,
OutlinerParaObject* pOutlinerObj, const tools::Rectangle& rCaptionRect,
- bool bShown, bool bAlwaysCreateCaption )
+ bool bShown )
{
OSL_ENSURE( pItemSet && pOutlinerObj, "ScNoteUtil::CreateNoteFromObjectData - item set and outliner object expected" );
ScNoteData aNoteData( bShown );
@@ -1264,7 +1264,7 @@ ScPostIt* ScNoteUtil::CreateNoteFromObjectData(
/* Create the note and insert it into the document. If the note is
visible, the caption object will be created automatically. */
- ScPostIt* pNote = new ScPostIt( rDoc, rPos, aNoteData, bAlwaysCreateCaption, 0/*nPostItId*/ );
+ ScPostIt* pNote = new ScPostIt( rDoc, rPos, aNoteData, /*bAlwaysCreateCaption*/false, 0/*nPostItId*/ );
pNote->AutoStamp();
rDoc.SetNote(rPos, pNote);
diff --git a/sc/source/filter/excel/xiescher.cxx b/sc/source/filter/excel/xiescher.cxx
index 989c9b693d0f..c5fbac78f43f 100644
--- a/sc/source/filter/excel/xiescher.cxx
+++ b/sc/source/filter/excel/xiescher.cxx
@@ -1826,8 +1826,7 @@ void XclImpNoteObj::DoPreProcessSdrObj( XclImpDffConverter& rDffConv, SdrObject&
rSdrObj.GetMergedItemSet().Clone(), // new object on heap expected
new OutlinerParaObject( *pOutlinerObj ), // new object on heap expected
rSdrObj.GetLogicRect(),
- ::get_flag( mnNoteFlags, EXC_NOTE_VISIBLE ),
- false );
+ ::get_flag( mnNoteFlags, EXC_NOTE_VISIBLE ) );
}
}
diff --git a/sc/source/filter/xml/xmlcelli.cxx b/sc/source/filter/xml/xmlcelli.cxx
index f8095c33eabf..c279deb63993 100644
--- a/sc/source/filter/xml/xmlcelli.cxx
+++ b/sc/source/filter/xml/xmlcelli.cxx
@@ -910,7 +910,7 @@ void ScXMLTableRowCellContext::SetAnnotation(const ScAddress& rPos)
// create cell note with all data from drawing object
pNote = ScNoteUtil::CreateNoteFromObjectData( *pDoc, rPos,
std::move(xItemSet), xOutlinerObj.release(),
- aCaptionRect, mxAnnotationData->mbShown, false );
+ aCaptionRect, mxAnnotationData->mbShown );
}
}
}
diff --git a/sc/source/ui/attrdlg/scdlgfact.cxx b/sc/source/ui/attrdlg/scdlgfact.cxx
index d1035d97a79a..f8d4b8f0d542 100644
--- a/sc/source/ui/attrdlg/scdlgfact.cxx
+++ b/sc/source/ui/attrdlg/scdlgfact.cxx
@@ -704,7 +704,7 @@ VclPtr<AbstractScDataFormDlg> ScAbstractDialogFactory_Impl::CreateScDataFormDlg(
VclPtr<AbstractScDeleteContentsDlg> ScAbstractDialogFactory_Impl::CreateScDeleteContentsDlg(weld::Window* pParent)
{
- return VclPtr<AbstractScDeleteContentsDlg_Impl>::Create(new ScDeleteContentsDlg(pParent, InsertDeleteFlags::NONE));
+ return VclPtr<AbstractScDeleteContentsDlg_Impl>::Create(new ScDeleteContentsDlg(pParent));
}
VclPtr<AbstractScFillSeriesDlg> ScAbstractDialogFactory_Impl::CreateScFillSeriesDlg( vcl::Window* pParent,
diff --git a/sc/source/ui/inc/delcodlg.hxx b/sc/source/ui/inc/delcodlg.hxx
index 00910bcb2cd9..d2f9e9535d8a 100644
--- a/sc/source/ui/inc/delcodlg.hxx
+++ b/sc/source/ui/inc/delcodlg.hxx
@@ -45,7 +45,7 @@ private:
DECL_LINK( DelAllHdl, weld::Button&, void );
public:
- ScDeleteContentsDlg(weld::Window* pParent, InsertDeleteFlags nCheckDefaults );
+ ScDeleteContentsDlg(weld::Window* pParent);
virtual ~ScDeleteContentsDlg() override;
void DisableObjects();
diff --git a/sc/source/ui/miscdlgs/delcodlg.cxx b/sc/source/ui/miscdlgs/delcodlg.cxx
index 19d098994c76..28b1169f22e9 100644
--- a/sc/source/ui/miscdlgs/delcodlg.cxx
+++ b/sc/source/ui/miscdlgs/delcodlg.cxx
@@ -26,7 +26,7 @@ InsertDeleteFlags ScDeleteContentsDlg::nPreviousChecks = (InsertDeleteFlags::D
InsertDeleteFlags::NOTE | InsertDeleteFlags::FORMULA |
InsertDeleteFlags::VALUE);
-ScDeleteContentsDlg::ScDeleteContentsDlg(weld::Window* pParent, InsertDeleteFlags nCheckDefaults)
+ScDeleteContentsDlg::ScDeleteContentsDlg(weld::Window* pParent)
: GenericDialogController(pParent, "modules/scalc/ui/deletecontents.ui", "DeleteContentsDialog")
, m_bObjectsDisabled(false)
, m_xBtnDelAll(m_xBuilder->weld_check_button("deleteall"))
@@ -39,12 +39,6 @@ ScDeleteContentsDlg::ScDeleteContentsDlg(weld::Window* pParent, InsertDeleteFlag
, m_xBtnDelObjects(m_xBuilder->weld_check_button("objects"))
, m_xBtnOk(m_xBuilder->weld_button("ok"))
{
- if ( nCheckDefaults != InsertDeleteFlags::NONE )
- {
- ScDeleteContentsDlg::nPreviousChecks = nCheckDefaults;
- ScDeleteContentsDlg::bPreviousAllCheck = false;
- }
-
m_xBtnDelAll->set_active( ScDeleteContentsDlg::bPreviousAllCheck );
m_xBtnDelStrings->set_active( bool(InsertDeleteFlags::STRING & ScDeleteContentsDlg::nPreviousChecks) );
m_xBtnDelNumbers->set_active( bool(InsertDeleteFlags::VALUE & ScDeleteContentsDlg::nPreviousChecks) );