summaryrefslogtreecommitdiff
path: root/chart2
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 /chart2
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 'chart2')
-rw-r--r--chart2/source/controller/dialogs/tp_AxisLabel.cxx16
-rw-r--r--chart2/source/controller/dialogs/tp_AxisLabel.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_AxisPositions.cxx14
-rw-r--r--chart2/source/controller/dialogs/tp_AxisPositions.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_DataLabel.cxx4
-rw-r--r--chart2/source/controller/dialogs/tp_DataLabel.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_ErrorBars.cxx4
-rw-r--r--chart2/source/controller/dialogs/tp_ErrorBars.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_LegendPosition.cxx6
-rw-r--r--chart2/source/controller/dialogs/tp_LegendPosition.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_PointGeometry.cxx4
-rw-r--r--chart2/source/controller/dialogs/tp_PointGeometry.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_PolarOptions.cxx8
-rw-r--r--chart2/source/controller/dialogs/tp_PolarOptions.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_Scale.cxx40
-rw-r--r--chart2/source/controller/dialogs/tp_Scale.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_SeriesToAxis.cxx20
-rw-r--r--chart2/source/controller/dialogs/tp_SeriesToAxis.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_TitleRotation.cxx8
-rw-r--r--chart2/source/controller/dialogs/tp_TitleRotation.hxx2
-rw-r--r--chart2/source/controller/dialogs/tp_Trendline.cxx4
-rw-r--r--chart2/source/controller/dialogs/tp_Trendline.hxx2
22 files changed, 75 insertions, 75 deletions
diff --git a/chart2/source/controller/dialogs/tp_AxisLabel.cxx b/chart2/source/controller/dialogs/tp_AxisLabel.cxx
index 2c9a4663adbc..9883b6496dca 100644
--- a/chart2/source/controller/dialogs/tp_AxisLabel.cxx
+++ b/chart2/source/controller/dialogs/tp_AxisLabel.cxx
@@ -135,12 +135,12 @@ bool SchAxisLabelTabPage::FillItemSet( SfxItemSet* rOutAttrs )
return true;
}
-void SchAxisLabelTabPage::Reset( const SfxItemSet& rInAttrs )
+void SchAxisLabelTabPage::Reset( const SfxItemSet* rInAttrs )
{
const SfxPoolItem* pPoolItem = NULL;
// show description
- SfxItemState aState = rInAttrs.GetItemState( SCHATTR_AXIS_SHOWDESCR, false, &pPoolItem );
+ SfxItemState aState = rInAttrs->GetItemState( SCHATTR_AXIS_SHOWDESCR, false, &pPoolItem );
if( aState == SFX_ITEM_DONTCARE )
{
m_pCbShowDescription->EnableTriState( true );
@@ -162,7 +162,7 @@ void SchAxisLabelTabPage::Reset( const SfxItemSet& rInAttrs )
// check new degree item
m_nInitialDegrees = 0;
- aState = rInAttrs.GetItemState( SCHATTR_TEXT_DEGREES, false, &pPoolItem );
+ aState = rInAttrs->GetItemState( SCHATTR_TEXT_DEGREES, false, &pPoolItem );
if( aState == SFX_ITEM_SET )
m_nInitialDegrees = static_cast< const SfxInt32Item * >( pPoolItem )->GetValue();
@@ -174,7 +174,7 @@ void SchAxisLabelTabPage::Reset( const SfxItemSet& rInAttrs )
// check stacked item
m_bInitialStacking = false;
- aState = rInAttrs.GetItemState( SCHATTR_TEXT_STACKED, false, &pPoolItem );
+ aState = rInAttrs->GetItemState( SCHATTR_TEXT_STACKED, false, &pPoolItem );
if( aState == SFX_ITEM_SET )
m_bInitialStacking = static_cast< const SfxBoolItem * >( pPoolItem )->GetValue();
@@ -184,11 +184,11 @@ void SchAxisLabelTabPage::Reset( const SfxItemSet& rInAttrs )
else
m_pOrientHlp->SetStackedState( TRISTATE_INDET );
- if( rInAttrs.GetItemState( EE_PARA_WRITINGDIR, true, &pPoolItem ) == SFX_ITEM_SET )
+ if( rInAttrs->GetItemState( EE_PARA_WRITINGDIR, true, &pPoolItem ) == SFX_ITEM_SET )
m_pLbTextDirection->SelectEntryValue( SvxFrameDirection(((const SvxFrameDirectionItem*)pPoolItem)->GetValue()) );
// Text overlap ----------
- aState = rInAttrs.GetItemState( SCHATTR_AXIS_LABEL_OVERLAP, false, &pPoolItem );
+ aState = rInAttrs->GetItemState( SCHATTR_AXIS_LABEL_OVERLAP, false, &pPoolItem );
if( aState == SFX_ITEM_DONTCARE )
{
m_pCbTextOverlap->EnableTriState( true );
@@ -207,7 +207,7 @@ void SchAxisLabelTabPage::Reset( const SfxItemSet& rInAttrs )
}
// text break ----------
- aState = rInAttrs.GetItemState( SCHATTR_AXIS_LABEL_BREAK, false, &pPoolItem );
+ aState = rInAttrs->GetItemState( SCHATTR_AXIS_LABEL_BREAK, false, &pPoolItem );
if( aState == SFX_ITEM_DONTCARE )
{
m_pCbTextBreak->EnableTriState( true );
@@ -232,7 +232,7 @@ void SchAxisLabelTabPage::Reset( const SfxItemSet& rInAttrs )
// text order ----------
if( m_bShowStaggeringControls )
{
- aState = rInAttrs.GetItemState( SCHATTR_AXIS_LABEL_ORDER, false, &pPoolItem );
+ aState = rInAttrs->GetItemState( SCHATTR_AXIS_LABEL_ORDER, false, &pPoolItem );
if( aState == SFX_ITEM_SET )
{
SvxChartTextOrder eOrder = static_cast< const SvxChartTextOrderItem * >( pPoolItem )->GetValue();
diff --git a/chart2/source/controller/dialogs/tp_AxisLabel.hxx b/chart2/source/controller/dialogs/tp_AxisLabel.hxx
index 115da2737cfc..838ea1bf131a 100644
--- a/chart2/source/controller/dialogs/tp_AxisLabel.hxx
+++ b/chart2/source/controller/dialogs/tp_AxisLabel.hxx
@@ -76,7 +76,7 @@ public:
static SfxTabPage* Create( Window* pParent, const SfxItemSet& rInAttrs );
virtual bool FillItemSet( SfxItemSet* rOutAttrs ) SAL_OVERRIDE;
- virtual void Reset( const SfxItemSet& rInAttrs ) SAL_OVERRIDE;
+ virtual void Reset( const SfxItemSet* rInAttrs ) SAL_OVERRIDE;
void ShowStaggeringControls( bool bShowStaggeringControls );
void SetComplexCategories( bool bComplexCategories );
diff --git a/chart2/source/controller/dialogs/tp_AxisPositions.cxx b/chart2/source/controller/dialogs/tp_AxisPositions.cxx
index 461ba55ab77f..a43a104bdedb 100644
--- a/chart2/source/controller/dialogs/tp_AxisPositions.cxx
+++ b/chart2/source/controller/dialogs/tp_AxisPositions.cxx
@@ -131,7 +131,7 @@ bool AxisPositionsTabPage::FillItemSet(SfxItemSet* rOutAttrs)
return true;
}
-void AxisPositionsTabPage::Reset(const SfxItemSet& rInAttrs)
+void AxisPositionsTabPage::Reset(const SfxItemSet* rInAttrs)
{
//init and enable controls
m_pED_CrossesAt->Show( !m_bCrossingAxisIsCategoryAxis );
@@ -160,7 +160,7 @@ void AxisPositionsTabPage::Reset(const SfxItemSet& rInAttrs)
const SfxPoolItem *pPoolItem = NULL;
//axis line
- if(rInAttrs.GetItemState(SCHATTR_AXIS_POSITION,true, &pPoolItem)== SFX_ITEM_SET)
+ if(rInAttrs->GetItemState(SCHATTR_AXIS_POSITION,true, &pPoolItem)== SFX_ITEM_SET)
{
bool bZero = false;
sal_Int32 nPos = static_cast< const SfxInt32Item * >( pPoolItem )->GetValue();
@@ -177,7 +177,7 @@ void AxisPositionsTabPage::Reset(const SfxItemSet& rInAttrs)
m_pLB_CrossesAt->SelectEntryPos( nPos );
CrossesAtSelectHdl( (void*)0 );
- if( rInAttrs.GetItemState(SCHATTR_AXIS_POSITION_VALUE,true, &pPoolItem)== SFX_ITEM_SET || bZero )
+ if( rInAttrs->GetItemState(SCHATTR_AXIS_POSITION_VALUE,true, &pPoolItem)== SFX_ITEM_SET || bZero )
{
double fCrossover = 0.0;
if( !bZero )
@@ -200,7 +200,7 @@ void AxisPositionsTabPage::Reset(const SfxItemSet& rInAttrs)
}
// Labels
- if( rInAttrs.GetItemState( SCHATTR_AXIS_LABEL_POSITION, false, &pPoolItem ) == SFX_ITEM_SET )
+ if( rInAttrs->GetItemState( SCHATTR_AXIS_LABEL_POSITION, false, &pPoolItem ) == SFX_ITEM_SET )
{
sal_Int32 nPos = static_cast< const SfxInt32Item * >( pPoolItem )->GetValue();
if( nPos < m_pLB_PlaceLabels->GetEntryCount() )
@@ -212,9 +212,9 @@ void AxisPositionsTabPage::Reset(const SfxItemSet& rInAttrs)
// Tick marks
long nTicks = 0, nMinorTicks = 0;
- if(rInAttrs.GetItemState(SCHATTR_AXIS_TICKS,true, &pPoolItem)== SFX_ITEM_SET)
+ if(rInAttrs->GetItemState(SCHATTR_AXIS_TICKS,true, &pPoolItem)== SFX_ITEM_SET)
nTicks = ((const SfxInt32Item*)pPoolItem)->GetValue();
- if(rInAttrs.GetItemState(SCHATTR_AXIS_HELPTICKS,true, &pPoolItem)== SFX_ITEM_SET)
+ if(rInAttrs->GetItemState(SCHATTR_AXIS_HELPTICKS,true, &pPoolItem)== SFX_ITEM_SET)
nMinorTicks = ((const SfxInt32Item*)pPoolItem)->GetValue();
m_pCB_TicksInner->Check(bool(nTicks&CHAXIS_MARK_INNER));
@@ -223,7 +223,7 @@ void AxisPositionsTabPage::Reset(const SfxItemSet& rInAttrs)
m_pCB_MinorOuter->Check(bool(nMinorTicks&CHAXIS_MARK_OUTER));
// Tick position
- if( rInAttrs.GetItemState( SCHATTR_AXIS_MARK_POSITION, false, &pPoolItem ) == SFX_ITEM_SET )
+ if( rInAttrs->GetItemState( SCHATTR_AXIS_MARK_POSITION, false, &pPoolItem ) == SFX_ITEM_SET )
{
sal_Int32 nPos = static_cast< const SfxInt32Item * >( pPoolItem )->GetValue();
if( nPos < m_pLB_PlaceTicks->GetEntryCount() )
diff --git a/chart2/source/controller/dialogs/tp_AxisPositions.hxx b/chart2/source/controller/dialogs/tp_AxisPositions.hxx
index d34997b82ca8..d05bbabeed1b 100644
--- a/chart2/source/controller/dialogs/tp_AxisPositions.hxx
+++ b/chart2/source/controller/dialogs/tp_AxisPositions.hxx
@@ -36,7 +36,7 @@ public:
static SfxTabPage* Create( Window* pParent, const SfxItemSet& rInAttrs );
virtual bool FillItemSet( SfxItemSet* rOutAttrs ) SAL_OVERRIDE;
- virtual void Reset( const SfxItemSet& rInAttrs ) SAL_OVERRIDE;
+ virtual void Reset( const SfxItemSet* rInAttrs ) SAL_OVERRIDE;
using TabPage::DeactivatePage;
virtual int DeactivatePage( SfxItemSet* pItemSet = NULL ) SAL_OVERRIDE;
diff --git a/chart2/source/controller/dialogs/tp_DataLabel.cxx b/chart2/source/controller/dialogs/tp_DataLabel.cxx
index 417544dbc565..5c77535cbe79 100644
--- a/chart2/source/controller/dialogs/tp_DataLabel.cxx
+++ b/chart2/source/controller/dialogs/tp_DataLabel.cxx
@@ -48,9 +48,9 @@ bool DataLabelsTabPage::FillItemSet(SfxItemSet* rOutAttrs)
return m_aDataLabelResources.FillItemSet(rOutAttrs);
}
-void DataLabelsTabPage::Reset(const SfxItemSet& rInAttrs)
+void DataLabelsTabPage::Reset(const SfxItemSet* rInAttrs)
{
- m_aDataLabelResources.Reset(rInAttrs);
+ m_aDataLabelResources.Reset(*rInAttrs);
}
void DataLabelsTabPage::SetNumberFormatter( SvNumberFormatter* pFormatter )
diff --git a/chart2/source/controller/dialogs/tp_DataLabel.hxx b/chart2/source/controller/dialogs/tp_DataLabel.hxx
index 74946771c33e..32981ce59a0c 100644
--- a/chart2/source/controller/dialogs/tp_DataLabel.hxx
+++ b/chart2/source/controller/dialogs/tp_DataLabel.hxx
@@ -40,7 +40,7 @@ public:
void SetNumberFormatter( SvNumberFormatter* pFormatter );
- virtual void Reset(const SfxItemSet& rInAttrs) SAL_OVERRIDE;
+ virtual void Reset(const SfxItemSet* rInAttrs) SAL_OVERRIDE;
virtual bool FillItemSet(SfxItemSet* rOutAttrs) SAL_OVERRIDE;
private:
diff --git a/chart2/source/controller/dialogs/tp_ErrorBars.cxx b/chart2/source/controller/dialogs/tp_ErrorBars.cxx
index f0fc68d5d6b1..225c607735b3 100644
--- a/chart2/source/controller/dialogs/tp_ErrorBars.cxx
+++ b/chart2/source/controller/dialogs/tp_ErrorBars.cxx
@@ -52,9 +52,9 @@ bool ErrorBarsTabPage::FillItemSet( SfxItemSet* rOutAttrs )
return m_aErrorBarResources.FillItemSet( *rOutAttrs );
}
-void ErrorBarsTabPage::Reset( const SfxItemSet& rInAttrs )
+void ErrorBarsTabPage::Reset( const SfxItemSet* rInAttrs )
{
- m_aErrorBarResources.Reset( rInAttrs );
+ m_aErrorBarResources.Reset( *rInAttrs );
}
void ErrorBarsTabPage::DataChanged( const DataChangedEvent& rDCEvt )
diff --git a/chart2/source/controller/dialogs/tp_ErrorBars.hxx b/chart2/source/controller/dialogs/tp_ErrorBars.hxx
index 838310cd639d..96b14dc0199c 100644
--- a/chart2/source/controller/dialogs/tp_ErrorBars.hxx
+++ b/chart2/source/controller/dialogs/tp_ErrorBars.hxx
@@ -39,7 +39,7 @@ public:
static SfxTabPage* Create( Window* pParent, const SfxItemSet& rInAttrs );
virtual bool FillItemSet( SfxItemSet* rOutAttrs ) SAL_OVERRIDE;
- virtual void Reset( const SfxItemSet& rInAttrs ) SAL_OVERRIDE;
+ virtual void Reset( const SfxItemSet* rInAttrs ) SAL_OVERRIDE;
virtual void DataChanged( const DataChangedEvent& rDCEvt ) SAL_OVERRIDE;
diff --git a/chart2/source/controller/dialogs/tp_LegendPosition.cxx b/chart2/source/controller/dialogs/tp_LegendPosition.cxx
index eba17ae0ec53..b932a53eca3c 100644
--- a/chart2/source/controller/dialogs/tp_LegendPosition.cxx
+++ b/chart2/source/controller/dialogs/tp_LegendPosition.cxx
@@ -56,12 +56,12 @@ bool SchLegendPosTabPage::FillItemSet(SfxItemSet* rOutAttrs)
return true;
}
-void SchLegendPosTabPage::Reset(const SfxItemSet& rInAttrs)
+void SchLegendPosTabPage::Reset(const SfxItemSet* rInAttrs)
{
- m_aLegendPositionResources.initFromItemSet(rInAttrs);
+ m_aLegendPositionResources.initFromItemSet(*rInAttrs);
const SfxPoolItem* pPoolItem = 0;
- if( rInAttrs.GetItemState( EE_PARA_WRITINGDIR, true, &pPoolItem ) == SFX_ITEM_SET )
+ if( rInAttrs->GetItemState( EE_PARA_WRITINGDIR, true, &pPoolItem ) == SFX_ITEM_SET )
m_pLbTextDirection->SelectEntryValue( SvxFrameDirection(((const SvxFrameDirectionItem*)pPoolItem)->GetValue()) );
}
diff --git a/chart2/source/controller/dialogs/tp_LegendPosition.hxx b/chart2/source/controller/dialogs/tp_LegendPosition.hxx
index 091f639f50dc..2c4a855d539f 100644
--- a/chart2/source/controller/dialogs/tp_LegendPosition.hxx
+++ b/chart2/source/controller/dialogs/tp_LegendPosition.hxx
@@ -40,7 +40,7 @@ public:
static SfxTabPage* Create(Window* pParent, const SfxItemSet& rInAttrs);
virtual bool FillItemSet(SfxItemSet* rOutAttrs) SAL_OVERRIDE;
- virtual void Reset(const SfxItemSet& rInAttrs) SAL_OVERRIDE;
+ virtual void Reset(const SfxItemSet* rInAttrs) SAL_OVERRIDE;
};
} //namespace chart
diff --git a/chart2/source/controller/dialogs/tp_PointGeometry.cxx b/chart2/source/controller/dialogs/tp_PointGeometry.cxx
index cbdd53294a65..03b221426ad8 100644
--- a/chart2/source/controller/dialogs/tp_PointGeometry.cxx
+++ b/chart2/source/controller/dialogs/tp_PointGeometry.cxx
@@ -65,11 +65,11 @@ bool SchLayoutTabPage::FillItemSet(SfxItemSet* rOutAttrs)
return true;
}
-void SchLayoutTabPage::Reset(const SfxItemSet& rInAttrs)
+void SchLayoutTabPage::Reset(const SfxItemSet* rInAttrs)
{
const SfxPoolItem *pPoolItem = NULL;
- if (rInAttrs.GetItemState(SCHATTR_STYLE_SHAPE,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_STYLE_SHAPE,true, &pPoolItem) == SFX_ITEM_SET)
{
long nVal=((const SfxInt32Item*)pPoolItem)->GetValue();
if(m_pGeometryResources)
diff --git a/chart2/source/controller/dialogs/tp_PointGeometry.hxx b/chart2/source/controller/dialogs/tp_PointGeometry.hxx
index 69139520e429..fda04f3c95e1 100644
--- a/chart2/source/controller/dialogs/tp_PointGeometry.hxx
+++ b/chart2/source/controller/dialogs/tp_PointGeometry.hxx
@@ -33,7 +33,7 @@ public:
static SfxTabPage* Create(Window* pParent, const SfxItemSet& rInAttrs);
virtual bool FillItemSet(SfxItemSet* rOutAttrs) SAL_OVERRIDE;
- virtual void Reset(const SfxItemSet& rInAttrs) SAL_OVERRIDE;
+ virtual void Reset(const SfxItemSet* rInAttrs) SAL_OVERRIDE;
private:
BarGeometryResources* m_pGeometryResources;
diff --git a/chart2/source/controller/dialogs/tp_PolarOptions.cxx b/chart2/source/controller/dialogs/tp_PolarOptions.cxx
index 566ac73f6f56..f2731602d169 100644
--- a/chart2/source/controller/dialogs/tp_PolarOptions.cxx
+++ b/chart2/source/controller/dialogs/tp_PolarOptions.cxx
@@ -70,11 +70,11 @@ bool PolarOptionsTabPage::FillItemSet( SfxItemSet* rOutAttrs )
return true;
}
-void PolarOptionsTabPage::Reset(const SfxItemSet& rInAttrs)
+void PolarOptionsTabPage::Reset(const SfxItemSet* rInAttrs)
{
const SfxPoolItem *pPoolItem = NULL;
- if (rInAttrs.GetItemState(SCHATTR_STARTING_ANGLE, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_STARTING_ANGLE, true, &pPoolItem) == SFX_ITEM_SET)
{
long nTmp = (long)((const SfxInt32Item*)pPoolItem)->GetValue();
m_pAngleDial->SetRotation( nTmp*100 );
@@ -83,7 +83,7 @@ void PolarOptionsTabPage::Reset(const SfxItemSet& rInAttrs)
{
m_pFL_StartingAngle->Show(false);
}
- if (rInAttrs.GetItemState(SCHATTR_CLOCKWISE, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_CLOCKWISE, true, &pPoolItem) == SFX_ITEM_SET)
{
bool bCheck = static_cast< const SfxBoolItem * >( pPoolItem )->GetValue();
m_pCB_Clockwise->Check(bCheck);
@@ -92,7 +92,7 @@ void PolarOptionsTabPage::Reset(const SfxItemSet& rInAttrs)
{
m_pCB_Clockwise->Show(false);
}
- if (rInAttrs.GetItemState(SCHATTR_INCLUDE_HIDDEN_CELLS, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_INCLUDE_HIDDEN_CELLS, true, &pPoolItem) == SFX_ITEM_SET)
{
bool bVal = static_cast<const SfxBoolItem*>(pPoolItem)->GetValue();
m_pCB_IncludeHiddenCells->Check(bVal);
diff --git a/chart2/source/controller/dialogs/tp_PolarOptions.hxx b/chart2/source/controller/dialogs/tp_PolarOptions.hxx
index 3af8f463b333..dbdb15795afd 100644
--- a/chart2/source/controller/dialogs/tp_PolarOptions.hxx
+++ b/chart2/source/controller/dialogs/tp_PolarOptions.hxx
@@ -37,7 +37,7 @@ public:
static SfxTabPage* Create(Window* pParent, const SfxItemSet& rInAttrs);
virtual bool FillItemSet(SfxItemSet* rOutAttrs) SAL_OVERRIDE;
- virtual void Reset(const SfxItemSet& rInAttrs) SAL_OVERRIDE;
+ virtual void Reset(const SfxItemSet* rInAttrs) SAL_OVERRIDE;
private:
CheckBox* m_pCB_Clockwise;
diff --git a/chart2/source/controller/dialogs/tp_Scale.cxx b/chart2/source/controller/dialogs/tp_Scale.cxx
index 7f4b17ab8387..0f3a8ceeff51 100644
--- a/chart2/source/controller/dialogs/tp_Scale.cxx
+++ b/chart2/source/controller/dialogs/tp_Scale.cxx
@@ -273,24 +273,24 @@ bool ScaleTabPage::FillItemSet(SfxItemSet* rOutAttrs)
return true;
}
-void ScaleTabPage::Reset(const SfxItemSet& rInAttrs)
+void ScaleTabPage::Reset(const SfxItemSet* rInAttrs)
{
OSL_PRECOND( pNumFormatter, "No NumberFormatter available" );
if(!pNumFormatter)
return;
const SfxPoolItem *pPoolItem = NULL;
- if (rInAttrs.GetItemState(SCHATTR_AXIS_ALLOW_DATEAXIS, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_ALLOW_DATEAXIS, true, &pPoolItem) == SFX_ITEM_SET)
m_bAllowDateAxis = (bool) ((const SfxBoolItem*)pPoolItem)->GetValue();
m_nAxisType=chart2::AxisType::REALNUMBER;
- if (rInAttrs.GetItemState(SCHATTR_AXISTYPE, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXISTYPE, true, &pPoolItem) == SFX_ITEM_SET)
m_nAxisType = (int) ((const SfxInt32Item*)pPoolItem)->GetValue();
if( m_nAxisType==chart2::AxisType::DATE && !m_bAllowDateAxis )
m_nAxisType=chart2::AxisType::CATEGORY;
if( m_bAllowDateAxis )
{
bool bAutoDateAxis = false;
- if (rInAttrs.GetItemState(SCHATTR_AXIS_AUTO_DATEAXIS, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_AUTO_DATEAXIS, true, &pPoolItem) == SFX_ITEM_SET)
bAutoDateAxis = (bool) ((const SfxBoolItem*)pPoolItem)->GetValue();
sal_uInt16 nPos = 0;
@@ -310,66 +310,66 @@ void ScaleTabPage::Reset(const SfxItemSet& rInAttrs)
m_pCbxAutoOrigin->Check( true );
m_pCbx_AutoTimeResolution->Check( true );
- if (rInAttrs.GetItemState(SCHATTR_AXIS_AUTO_MIN,true,&pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_AUTO_MIN,true,&pPoolItem) == SFX_ITEM_SET)
m_pCbxAutoMin->Check(((const SfxBoolItem*)pPoolItem)->GetValue());
- if (rInAttrs.GetItemState(SCHATTR_AXIS_MIN,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_MIN,true, &pPoolItem) == SFX_ITEM_SET)
{
fMin = ((const SvxDoubleItem*)pPoolItem)->GetValue();
lcl_setValue( *m_pFmtFldMin, fMin );
}
- if (rInAttrs.GetItemState(SCHATTR_AXIS_AUTO_MAX,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_AUTO_MAX,true, &pPoolItem) == SFX_ITEM_SET)
m_pCbxAutoMax->Check(((const SfxBoolItem*)pPoolItem)->GetValue());
- if (rInAttrs.GetItemState(SCHATTR_AXIS_MAX,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_MAX,true, &pPoolItem) == SFX_ITEM_SET)
{
fMax = ((const SvxDoubleItem*)pPoolItem)->GetValue();
lcl_setValue( *m_pFmtFldMax, fMax );
}
- if (rInAttrs.GetItemState(SCHATTR_AXIS_AUTO_STEP_MAIN,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_AUTO_STEP_MAIN,true, &pPoolItem) == SFX_ITEM_SET)
m_pCbxAutoStepMain->Check(((const SfxBoolItem*)pPoolItem)->GetValue());
- if (rInAttrs.GetItemState(SCHATTR_AXIS_STEP_MAIN,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_STEP_MAIN,true, &pPoolItem) == SFX_ITEM_SET)
{
fStepMain = ((const SvxDoubleItem*)pPoolItem)->GetValue();
lcl_setValue( *m_pFmtFldStepMain, fStepMain );
m_pMt_MainDateStep->SetValue( static_cast<sal_Int32>(fStepMain) );
}
- if (rInAttrs.GetItemState(SCHATTR_AXIS_AUTO_STEP_HELP,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_AUTO_STEP_HELP,true, &pPoolItem) == SFX_ITEM_SET)
m_pCbxAutoStepHelp->Check(((const SfxBoolItem*)pPoolItem)->GetValue());
- if (rInAttrs.GetItemState(SCHATTR_AXIS_LOGARITHM,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_LOGARITHM,true, &pPoolItem) == SFX_ITEM_SET)
m_pCbxLogarithm->Check(((const SfxBoolItem*)pPoolItem)->GetValue());
- if (rInAttrs.GetItemState(SCHATTR_AXIS_REVERSE,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_REVERSE,true, &pPoolItem) == SFX_ITEM_SET)
m_pCbxReverse->Check(((const SfxBoolItem*)pPoolItem)->GetValue());
- if (rInAttrs.GetItemState(SCHATTR_AXIS_STEP_HELP,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_STEP_HELP,true, &pPoolItem) == SFX_ITEM_SET)
{
nStepHelp = ((const SfxInt32Item*)pPoolItem)->GetValue();
m_pMtStepHelp->SetValue( nStepHelp );
}
- if (rInAttrs.GetItemState(SCHATTR_AXIS_AUTO_ORIGIN,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_AUTO_ORIGIN,true, &pPoolItem) == SFX_ITEM_SET)
m_pCbxAutoOrigin->Check(((const SfxBoolItem*)pPoolItem)->GetValue());
- if (rInAttrs.GetItemState(SCHATTR_AXIS_ORIGIN,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_ORIGIN,true, &pPoolItem) == SFX_ITEM_SET)
{
fOrigin = ((const SvxDoubleItem*)pPoolItem)->GetValue();
lcl_setValue( *m_pFmtFldOrigin, fOrigin );
}
- if (rInAttrs.GetItemState(SCHATTR_AXIS_AUTO_TIME_RESOLUTION,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_AUTO_TIME_RESOLUTION,true, &pPoolItem) == SFX_ITEM_SET)
m_pCbx_AutoTimeResolution->Check(((const SfxBoolItem*)pPoolItem)->GetValue());
- if (rInAttrs.GetItemState(SCHATTR_AXIS_TIME_RESOLUTION,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_TIME_RESOLUTION,true, &pPoolItem) == SFX_ITEM_SET)
{
m_nTimeResolution = ((const SfxInt32Item*)pPoolItem)->GetValue();
m_pLB_TimeResolution->SelectEntryPos( m_nTimeResolution );
}
- if (rInAttrs.GetItemState(SCHATTR_AXIS_MAIN_TIME_UNIT,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_MAIN_TIME_UNIT,true, &pPoolItem) == SFX_ITEM_SET)
{
m_nMainTimeUnit = ((const SfxInt32Item*)pPoolItem)->GetValue();
m_pLB_MainTimeUnit->SelectEntryPos( m_nMainTimeUnit );
}
- if (rInAttrs.GetItemState(SCHATTR_AXIS_HELP_TIME_UNIT,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_HELP_TIME_UNIT,true, &pPoolItem) == SFX_ITEM_SET)
{
m_nHelpTimeUnit = ((const SfxInt32Item*)pPoolItem)->GetValue();
m_pLB_HelpTimeUnit->SelectEntryPos( m_nHelpTimeUnit );
diff --git a/chart2/source/controller/dialogs/tp_Scale.hxx b/chart2/source/controller/dialogs/tp_Scale.hxx
index b4980c3ca74d..9e754f7456a1 100644
--- a/chart2/source/controller/dialogs/tp_Scale.hxx
+++ b/chart2/source/controller/dialogs/tp_Scale.hxx
@@ -36,7 +36,7 @@ public:
static SfxTabPage* Create( Window* pParent, const SfxItemSet& rInAttrs );
virtual bool FillItemSet( SfxItemSet* rOutAttrs ) SAL_OVERRIDE;
- virtual void Reset( const SfxItemSet& rInAttrs ) SAL_OVERRIDE;
+ virtual void Reset( const SfxItemSet* rInAttrs ) SAL_OVERRIDE;
using TabPage::DeactivatePage;
virtual int DeactivatePage( SfxItemSet* pItemSet = NULL ) SAL_OVERRIDE;
diff --git a/chart2/source/controller/dialogs/tp_SeriesToAxis.cxx b/chart2/source/controller/dialogs/tp_SeriesToAxis.cxx
index d981cbc7a6be..b2c5cbb73335 100644
--- a/chart2/source/controller/dialogs/tp_SeriesToAxis.cxx
+++ b/chart2/source/controller/dialogs/tp_SeriesToAxis.cxx
@@ -115,13 +115,13 @@ bool SchOptionTabPage::FillItemSet(SfxItemSet* rOutAttrs)
return true;
}
-void SchOptionTabPage::Reset(const SfxItemSet& rInAttrs)
+void SchOptionTabPage::Reset(const SfxItemSet* rInAttrs)
{
const SfxPoolItem *pPoolItem = NULL;
m_pRbtAxis1->Check(true);
m_pRbtAxis2->Check(false);
- if (rInAttrs.GetItemState(SCHATTR_AXIS,true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS,true, &pPoolItem) == SFX_ITEM_SET)
{
long nVal=((const SfxInt32Item*)pPoolItem)->GetValue();
if(nVal==CHART_AXIS_SECONDARY_Y)
@@ -132,30 +132,30 @@ void SchOptionTabPage::Reset(const SfxItemSet& rInAttrs)
}
long nTmp;
- if (rInAttrs.GetItemState(SCHATTR_BAR_GAPWIDTH, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_BAR_GAPWIDTH, true, &pPoolItem) == SFX_ITEM_SET)
{
nTmp = (long)((const SfxInt32Item*)pPoolItem)->GetValue();
m_pMTGap->SetValue(nTmp);
}
- if (rInAttrs.GetItemState(SCHATTR_BAR_OVERLAP, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_BAR_OVERLAP, true, &pPoolItem) == SFX_ITEM_SET)
{
nTmp = (long)((const SfxInt32Item*)pPoolItem)->GetValue();
m_pMTOverlap->SetValue(nTmp);
}
- if (rInAttrs.GetItemState(SCHATTR_BAR_CONNECT, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_BAR_CONNECT, true, &pPoolItem) == SFX_ITEM_SET)
{
bool bCheck = static_cast< const SfxBoolItem * >( pPoolItem )->GetValue();
m_pCBConnect->Check(bCheck);
}
- if (rInAttrs.GetItemState(SCHATTR_AXIS_FOR_ALL_SERIES, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_AXIS_FOR_ALL_SERIES, true, &pPoolItem) == SFX_ITEM_SET)
{
m_nAllSeriesAxisIndex = static_cast< const SfxInt32Item * >( pPoolItem )->GetValue();
m_pCBAxisSideBySide->Disable();
}
- if (rInAttrs.GetItemState(SCHATTR_GROUP_BARS_PER_AXIS, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_GROUP_BARS_PER_AXIS, true, &pPoolItem) == SFX_ITEM_SET)
{
// model property is "group bars per axis", UI feature is the other way
// round: "show bars side by side"
@@ -170,10 +170,10 @@ void SchOptionTabPage::Reset(const SfxItemSet& rInAttrs)
//missing value treatment
{
::com::sun::star::uno::Sequence < sal_Int32 > aMissingValueTreatments;
- if( rInAttrs.GetItemState(SCHATTR_AVAILABLE_MISSING_VALUE_TREATMENTS, true, &pPoolItem) == SFX_ITEM_SET )
+ if( rInAttrs->GetItemState(SCHATTR_AVAILABLE_MISSING_VALUE_TREATMENTS, true, &pPoolItem) == SFX_ITEM_SET )
aMissingValueTreatments =((const SfxIntegerListItem*)pPoolItem)->GetConstSequence();
- if ( aMissingValueTreatments.getLength()>1 && rInAttrs.GetItemState(SCHATTR_MISSING_VALUE_TREATMENT,true, &pPoolItem) == SFX_ITEM_SET)
+ if ( aMissingValueTreatments.getLength()>1 && rInAttrs->GetItemState(SCHATTR_MISSING_VALUE_TREATMENT,true, &pPoolItem) == SFX_ITEM_SET)
{
m_pRB_DontPaint->Enable(false);
m_pRB_AssumeZero->Enable(false);
@@ -205,7 +205,7 @@ void SchOptionTabPage::Reset(const SfxItemSet& rInAttrs)
}
// Include hidden cells
- if (rInAttrs.GetItemState(SCHATTR_INCLUDE_HIDDEN_CELLS, true, &pPoolItem) == SFX_ITEM_SET)
+ if (rInAttrs->GetItemState(SCHATTR_INCLUDE_HIDDEN_CELLS, true, &pPoolItem) == SFX_ITEM_SET)
{
bool bVal = static_cast<const SfxBoolItem*>(pPoolItem)->GetValue();
m_pCBIncludeHiddenCells->Check(bVal);
diff --git a/chart2/source/controller/dialogs/tp_SeriesToAxis.hxx b/chart2/source/controller/dialogs/tp_SeriesToAxis.hxx
index 04f59dca13db..af969f7164fb 100644
--- a/chart2/source/controller/dialogs/tp_SeriesToAxis.hxx
+++ b/chart2/source/controller/dialogs/tp_SeriesToAxis.hxx
@@ -35,7 +35,7 @@ public:
static SfxTabPage* Create(Window* pParent, const SfxItemSet& rInAttrs);
virtual bool FillItemSet(SfxItemSet* rOutAttrs) SAL_OVERRIDE;
- virtual void Reset(const SfxItemSet& rInAttrs) SAL_OVERRIDE;
+ virtual void Reset(const SfxItemSet* rInAttrs) SAL_OVERRIDE;
void Init( bool bProvidesSecondaryYAxis, bool bProvidesOverlapAndGapWidth, bool bProvidesBarConnectors );
diff --git a/chart2/source/controller/dialogs/tp_TitleRotation.cxx b/chart2/source/controller/dialogs/tp_TitleRotation.cxx
index 5b9d4047c780..06e0ba13de09 100644
--- a/chart2/source/controller/dialogs/tp_TitleRotation.cxx
+++ b/chart2/source/controller/dialogs/tp_TitleRotation.cxx
@@ -87,18 +87,18 @@ bool SchAlignmentTabPage::FillItemSet(SfxItemSet* rOutAttrs)
return true;
}
-void SchAlignmentTabPage::Reset(const SfxItemSet& rInAttrs)
+void SchAlignmentTabPage::Reset(const SfxItemSet* rInAttrs)
{
- const SfxPoolItem* pItem = GetItem( rInAttrs, SCHATTR_TEXT_DEGREES );
+ const SfxPoolItem* pItem = GetItem( *rInAttrs, SCHATTR_TEXT_DEGREES );
sal_Int32 nDegrees = pItem ? ((const SfxInt32Item*)pItem)->GetValue() : 0;
m_pCtrlDial->SetRotation( nDegrees );
- pItem = GetItem( rInAttrs, SCHATTR_TEXT_STACKED );
+ pItem = GetItem( *rInAttrs, SCHATTR_TEXT_STACKED );
bool bStacked = pItem && ((const SfxBoolItem*)pItem)->GetValue();
m_pOrientHlp->SetStackedState( bStacked ? TRISTATE_TRUE : TRISTATE_FALSE );
- if( rInAttrs.GetItemState(EE_PARA_WRITINGDIR, true, &pItem) == SFX_ITEM_SET)
+ if( rInAttrs->GetItemState(EE_PARA_WRITINGDIR, true, &pItem) == SFX_ITEM_SET)
m_pLbTextDirection->SelectEntryValue( SvxFrameDirection(((const SvxFrameDirectionItem*)pItem)->GetValue()) );
}
diff --git a/chart2/source/controller/dialogs/tp_TitleRotation.hxx b/chart2/source/controller/dialogs/tp_TitleRotation.hxx
index dc468191e9be..4ec390093741 100644
--- a/chart2/source/controller/dialogs/tp_TitleRotation.hxx
+++ b/chart2/source/controller/dialogs/tp_TitleRotation.hxx
@@ -48,7 +48,7 @@ public:
static SfxTabPage* Create(Window* pParent, const SfxItemSet& rInAttrs);
static SfxTabPage* CreateWithoutRotation(Window* pParent, const SfxItemSet& rInAttrs);
virtual bool FillItemSet(SfxItemSet* rOutAttrs) SAL_OVERRIDE;
- virtual void Reset(const SfxItemSet& rInAttrs) SAL_OVERRIDE;
+ virtual void Reset(const SfxItemSet* rInAttrs) SAL_OVERRIDE;
};
} //namespace chart
diff --git a/chart2/source/controller/dialogs/tp_Trendline.cxx b/chart2/source/controller/dialogs/tp_Trendline.cxx
index b95acf9a14ea..d3753307c2ef 100644
--- a/chart2/source/controller/dialogs/tp_Trendline.cxx
+++ b/chart2/source/controller/dialogs/tp_Trendline.cxx
@@ -46,9 +46,9 @@ bool TrendlineTabPage::FillItemSet( SfxItemSet* rOutAttrs )
return m_aTrendlineResources.FillItemSet( rOutAttrs );
}
-void TrendlineTabPage::Reset( const SfxItemSet& rInAttrs )
+void TrendlineTabPage::Reset( const SfxItemSet* rInAttrs )
{
- m_aTrendlineResources.Reset( rInAttrs );
+ m_aTrendlineResources.Reset( *rInAttrs );
}
void TrendlineTabPage::DataChanged( const DataChangedEvent& rDCEvt )
diff --git a/chart2/source/controller/dialogs/tp_Trendline.hxx b/chart2/source/controller/dialogs/tp_Trendline.hxx
index b50a7d03d081..580dcc8fbc23 100644
--- a/chart2/source/controller/dialogs/tp_Trendline.hxx
+++ b/chart2/source/controller/dialogs/tp_Trendline.hxx
@@ -34,7 +34,7 @@ public:
static SfxTabPage* Create( Window* pParent, const SfxItemSet& rInAttrs );
virtual bool FillItemSet( SfxItemSet* rOutAttrs ) SAL_OVERRIDE;
- virtual void Reset( const SfxItemSet& rInAttrs ) SAL_OVERRIDE;
+ virtual void Reset( const SfxItemSet* rInAttrs ) SAL_OVERRIDE;
virtual void DataChanged( const DataChangedEvent& rDCEvt ) SAL_OVERRIDE;
void SetNumFormatter( SvNumberFormatter* pFormatter );