summaryrefslogtreecommitdiff
path: root/sw/source/ui/misc
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-06-11 10:35:24 +0200
committerStephan Bergmann <sbergman@redhat.com>2014-06-11 10:39:03 +0200
commita92e973b6d0a9ad87fe014442e1678af2ce0c7d0 (patch)
treeb39139c7992a853cc5e4d836fc35cd45c01a3f6d /sw/source/ui/misc
parent88f84eb1b0eebbb7e0a072f1e7001a9207ebbe9e (diff)
Change SfxTabPage::Reset param from ref to pointer
...there was a call site that passed undefined "null pointer reference" (apparently in a case where the passed argument was actually unused) Change-Id: I663d4264b7a84f44ca69c732f3bc502f614b2b2a
Diffstat (limited to 'sw/source/ui/misc')
-rw-r--r--sw/source/ui/misc/docfnote.cxx2
-rw-r--r--sw/source/ui/misc/impfnote.hxx2
-rw-r--r--sw/source/ui/misc/num.cxx4
-rw-r--r--sw/source/ui/misc/outline.cxx6
-rw-r--r--sw/source/ui/misc/pgfnote.cxx6
-rw-r--r--sw/source/ui/misc/pggrid.cxx8
6 files changed, 14 insertions, 14 deletions
diff --git a/sw/source/ui/misc/docfnote.cxx b/sw/source/ui/misc/docfnote.cxx
index 86c99c966613..4d0a8ff51bf1 100644
--- a/sw/source/ui/misc/docfnote.cxx
+++ b/sw/source/ui/misc/docfnote.cxx
@@ -117,7 +117,7 @@ SwEndNoteOptionPage::SwEndNoteOptionPage(Window *pParent, bool bEN,
get(m_pFtnCharTextTemplBox, "charstylelb");
}
-void SwEndNoteOptionPage::Reset( const SfxItemSet& )
+void SwEndNoteOptionPage::Reset( const SfxItemSet* )
{
boost::scoped_ptr<SwEndNoteInfo> pInf(bEndNote ? new SwEndNoteInfo( pSh->GetEndNoteInfo() )
: new SwFtnInfo( pSh->GetFtnInfo() ));
diff --git a/sw/source/ui/misc/impfnote.hxx b/sw/source/ui/misc/impfnote.hxx
index 349a43194e51..14f2a2f06e7c 100644
--- a/sw/source/ui/misc/impfnote.hxx
+++ b/sw/source/ui/misc/impfnote.hxx
@@ -73,7 +73,7 @@ public:
static SfxTabPage *Create(Window *pParent, const SfxItemSet &rSet);
virtual bool FillItemSet(SfxItemSet *rSet) SAL_OVERRIDE;
- virtual void Reset( const SfxItemSet& ) SAL_OVERRIDE;
+ virtual void Reset( const SfxItemSet* ) SAL_OVERRIDE;
void SetShell( SwWrtShell &rShell );
};
diff --git a/sw/source/ui/misc/num.cxx b/sw/source/ui/misc/num.cxx
index 1bf0db625ce6..bd05757d7f36 100644
--- a/sw/source/ui/misc/num.cxx
+++ b/sw/source/ui/misc/num.cxx
@@ -420,7 +420,7 @@ bool SwNumPositionTabPage::FillItemSet( SfxItemSet* rSet )
return bModified;
}
-void SwNumPositionTabPage::Reset( const SfxItemSet& rSet )
+void SwNumPositionTabPage::Reset( const SfxItemSet* rSet )
{
const SfxPoolItem* pItem;
if(pOutlineDlg)
@@ -428,7 +428,7 @@ void SwNumPositionTabPage::Reset( const SfxItemSet& rSet )
pSaveNum = pOutlineDlg->GetNumRule();
m_pLevelLB->EnableMultiSelection(false);
}
- else if(SFX_ITEM_SET == rSet.GetItemState(FN_PARAM_ACT_NUMBER, false, &pItem))
+ else if(SFX_ITEM_SET == rSet->GetItemState(FN_PARAM_ACT_NUMBER, false, &pItem))
pSaveNum = ((SwUINumRuleItem*)pItem)->GetNumRule();
nActNumLvl = SwOutlineTabDialog::GetActNumLevel();
diff --git a/sw/source/ui/misc/outline.cxx b/sw/source/ui/misc/outline.cxx
index a7ce9a4d4028..1fe589e836c6 100644
--- a/sw/source/ui/misc/outline.cxx
+++ b/sw/source/ui/misc/outline.cxx
@@ -301,7 +301,7 @@ IMPL_LINK( SwOutlineTabDialog, MenuSelectHdl, Menu *, pMenu )
sal_uInt16 nPageId = GetCurPageId();
SfxTabPage* pPage = GetTabPage( nPageId );
- pPage->Reset(*GetOutputItemSet());
+ pPage->Reset(GetOutputItemSet());
return 0;
}
@@ -822,9 +822,9 @@ bool SwOutlineSettingsTabPage::FillItemSet( SfxItemSet* )
return true;
}
-void SwOutlineSettingsTabPage::Reset( const SfxItemSet& rSet )
+void SwOutlineSettingsTabPage::Reset( const SfxItemSet* rSet )
{
- ActivatePage(rSet);
+ ActivatePage(*rSet);
}
SfxTabPage* SwOutlineSettingsTabPage::Create( Window* pParent,
diff --git a/sw/source/ui/misc/pgfnote.cxx b/sw/source/ui/misc/pgfnote.cxx
index 600905f847c9..a447814121bf 100644
--- a/sw/source/ui/misc/pgfnote.cxx
+++ b/sw/source/ui/misc/pgfnote.cxx
@@ -141,12 +141,12 @@ SfxTabPage* SwFootNotePage::Create(Window *pParent, const SfxItemSet &rSet)
return new SwFootNotePage(pParent, rSet);
}
-void SwFootNotePage::Reset(const SfxItemSet &rSet)
+void SwFootNotePage::Reset(const SfxItemSet *rSet)
{
// if no example exists, otherwise Init here in Activate
boost::scoped_ptr<SwPageFtnInfo> pDefFtnInfo;
const SwPageFtnInfo* pFtnInfo;
- const SfxPoolItem* pItem = SfxTabPage::GetItem(rSet, FN_PARAM_FTN_INFO);
+ const SfxPoolItem* pItem = SfxTabPage::GetItem(*rSet, FN_PARAM_FTN_INFO);
if( pItem )
{
pFtnInfo = &((const SwPageFtnInfoItem*)pItem)->GetPageFtnInfo();
@@ -250,7 +250,7 @@ void SwFootNotePage::Reset(const SfxItemSet &rSet)
m_pDistEdit->SetValue(m_pDistEdit->Normalize(pFtnInfo->GetTopDist()),FUNIT_TWIP);
m_pLineDistEdit->SetValue(
m_pLineDistEdit->Normalize(pFtnInfo->GetBottomDist()), FUNIT_TWIP);
- ActivatePage( rSet );
+ ActivatePage( *rSet );
}
// stuff attributes into the set, when OK
diff --git a/sw/source/ui/misc/pggrid.cxx b/sw/source/ui/misc/pggrid.cxx
index 017d2a530a42..452be968e796 100644
--- a/sw/source/ui/misc/pggrid.cxx
+++ b/sw/source/ui/misc/pggrid.cxx
@@ -187,11 +187,11 @@ bool SwTextGridPage::FillItemSet(SfxItemSet *rSet)
return bRet;
}
-void SwTextGridPage::Reset(const SfxItemSet &rSet)
+void SwTextGridPage::Reset(const SfxItemSet *rSet)
{
- if(SFX_ITEM_AVAILABLE <= rSet.GetItemState(RES_TEXTGRID, true))
+ if(SFX_ITEM_AVAILABLE <= rSet->GetItemState(RES_TEXTGRID, true))
{
- const SwTextGridItem& rGridItem = (const SwTextGridItem&)rSet.Get(RES_TEXTGRID);
+ const SwTextGridItem& rGridItem = (const SwTextGridItem&)rSet->Get(RES_TEXTGRID);
RadioButton* pButton = 0;
switch(rGridItem.GetGridType())
{
@@ -214,7 +214,7 @@ void SwTextGridPage::Reset(const SfxItemSet &rSet)
m_pPrintCB->Check(rGridItem.IsPrintGrid());
m_pColorLB->SelectEntry(rGridItem.GetColor());
}
- UpdatePageSize(rSet);
+ UpdatePageSize(*rSet);
m_pNoGridRB->SaveValue();
m_pLinesGridRB->SaveValue();