diff options
author | Kohei Yoshida <kohei.yoshida@suse.com> | 2012-02-22 15:32:32 -0500 |
---|---|---|
committer | Kohei Yoshida <kohei.yoshida@suse.com> | 2012-02-22 15:41:59 -0500 |
commit | 32b074bef73e44df397145fbc5e984713f4ef995 (patch) | |
tree | 9f715e5cf84ab3f031d0fe6005d14f01f197d9a0 /sc/source/ui/view | |
parent | 21aec7e5d724042773d9d5ea39f477113ace0c39 (diff) |
Slight cleanup.
No need to make a duplicate of ScDPObject.
Diffstat (limited to 'sc/source/ui/view')
-rw-r--r-- | sc/source/ui/view/dbfunc3.cxx | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/sc/source/ui/view/dbfunc3.cxx b/sc/source/ui/view/dbfunc3.cxx index abfe1fb3b06f..ca1de035b2a3 100644 --- a/sc/source/ui/view/dbfunc3.cxx +++ b/sc/source/ui/view/dbfunc3.cxx @@ -1437,7 +1437,7 @@ void ScDBFunc::DataPilotInput( const ScAddress& rPos, const rtl::OUString& rStri pDPObj->BuildAllDimensionMembers(); ScDPSaveData aData( *pDPObj->GetSaveData() ); - sal_Bool bChange = false; + bool bChange = false; sal_uInt16 nOrient = DataPilotFieldOrientation_HIDDEN; long nField = pDPObj->GetHeaderDim( rPos, nOrient ); @@ -1461,7 +1461,7 @@ void ScDBFunc::DataPilotInput( const ScAddress& rPos, const rtl::OUString& rStri ScDPSaveDimension* pSaveDim = aData.GetDimensionByName( aOldText ); pSaveDim->SetName( rString ); - bChange = sal_True; + bChange = true; } else nErrorId = STR_INVALIDNAME; @@ -1675,10 +1675,8 @@ void ScDBFunc::DataPilotInput( const ScAddress& rPos, const rtl::OUString& rStri { // apply changes ScDBDocFunc aFunc( *GetViewData()->GetDocShell() ); - ScDPObject* pNewObj = new ScDPObject( *pDPObj ); - pNewObj->SetSaveData( aData ); - aFunc.DataPilotUpdate( pDPObj, pNewObj, sal_True, false ); - delete pNewObj; + pDPObj->SetSaveData( aData ); + aFunc.DataPilotUpdate( pDPObj, pDPObj, true, false ); } else { |