diff options
author | Noel Grandin <noel@peralex.com> | 2016-03-18 11:02:37 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2016-03-18 11:03:00 +0200 |
commit | 0008c67004d3eb8e1fc7a5e13cd50269ba80e7d2 (patch) | |
tree | f366492e90770d9a2c5bfcc8e2f38eae01095e72 /sd/source/ui | |
parent | f1ff9375184607b86ae8807d7cf1220962425b51 (diff) |
drop unused params from SvLBoxItem and all it's subclasses
looks like this is fallout from commit
ac7acb0a "Merged SvTreeListBox and SvLBox."
(in year 2012)
Change-Id: Iaebeae64fc7cd3ba11f5f45b53bcb65bf906e906
Diffstat (limited to 'sd/source/ui')
-rw-r--r-- | sd/source/ui/animations/CustomAnimationList.cxx | 25 | ||||
-rw-r--r-- | sd/source/ui/dlg/dlgassim.cxx | 19 | ||||
-rw-r--r-- | sd/source/ui/dlg/sdtreelb.cxx | 2 |
3 files changed, 19 insertions, 27 deletions
diff --git a/sd/source/ui/animations/CustomAnimationList.cxx b/sd/source/ui/animations/CustomAnimationList.cxx index dcbefcaf8b49..07138faa9c04 100644 --- a/sd/source/ui/animations/CustomAnimationList.cxx +++ b/sd/source/ui/animations/CustomAnimationList.cxx @@ -35,6 +35,7 @@ #include <vcl/svapp.hxx> #include <vcl/settings.hxx> #include <vcl/builderfactory.hxx> +#include <o3tl/make_unique.hxx> #include "sdresid.hxx" @@ -203,7 +204,7 @@ static OUString getDescription( const Any& rTarget, bool bWithText = true ) class CustomAnimationListEntryItem : public SvLBoxString { public: - CustomAnimationListEntryItem(SvTreeListEntry*, sal_uInt16 nFlags, const OUString& aDescription, + CustomAnimationListEntryItem(const OUString& aDescription, CustomAnimationEffectPtr pEffect, CustomAnimationList* pParent); virtual ~CustomAnimationListEntryItem(); void InitViewData(SvTreeListBox*,SvTreeListEntry*,SvViewDataItem*) override; @@ -222,8 +223,8 @@ private: const long nItemMinHeight = 38; }; -CustomAnimationListEntryItem::CustomAnimationListEntryItem( SvTreeListEntry* pEntry, sal_uInt16 nFlags, const OUString& aDescription, CustomAnimationEffectPtr pEffect, CustomAnimationList* pParent ) -: SvLBoxString( pEntry, nFlags, aDescription ) +CustomAnimationListEntryItem::CustomAnimationListEntryItem( const OUString& aDescription, CustomAnimationEffectPtr pEffect, CustomAnimationList* pParent ) +: SvLBoxString( aDescription ) , mpParent( pParent ) , msDescription( aDescription ) , msEffectName( OUString() ) @@ -376,7 +377,7 @@ CustomAnimationListEntry::~CustomAnimationListEntry() class CustomAnimationTriggerEntryItem : public SvLBoxString { public: - CustomAnimationTriggerEntryItem( SvTreeListEntry*,sal_uInt16 nFlags, const OUString& aDescription ); + CustomAnimationTriggerEntryItem( const OUString& aDescription ); virtual ~CustomAnimationTriggerEntryItem(); void InitViewData( SvTreeListBox*,SvTreeListEntry*,SvViewDataItem* ) override; SvLBoxItem* Create() const override; @@ -389,8 +390,8 @@ private: const long nIconWidth = 19; }; -CustomAnimationTriggerEntryItem::CustomAnimationTriggerEntryItem( SvTreeListEntry* pEntry, sal_uInt16 nFlags, const OUString& aDescription ) -: SvLBoxString( pEntry, nFlags, aDescription ), msDescription( aDescription ) +CustomAnimationTriggerEntryItem::CustomAnimationTriggerEntryItem( const OUString& aDescription ) +: SvLBoxString( aDescription ), msDescription( aDescription ) { } @@ -656,13 +657,11 @@ void CustomAnimationList::update() if( xShape.is() ) { SvTreeListEntry* pLBoxEntry = new CustomAnimationListEntry; - pLBoxEntry->AddItem(std::unique_ptr<SvLBoxContextBmp>( - new SvLBoxContextBmp(pLBoxEntry, 0, Image(), Image(), false))); + pLBoxEntry->AddItem(o3tl::make_unique<SvLBoxContextBmp>(Image(), Image(), false)); OUString aDescription = SD_RESSTR(STR_CUSTOMANIMATION_TRIGGER); aDescription += ": "; aDescription += getShapeDescription( xShape, false ); - pLBoxEntry->AddItem(std::unique_ptr<CustomAnimationTriggerEntryItem>( - new CustomAnimationTriggerEntryItem(pLBoxEntry, 0, aDescription))); + pLBoxEntry->AddItem(o3tl::make_unique<CustomAnimationTriggerEntryItem>(aDescription)); Insert( pLBoxEntry ); SvViewDataEntry* pViewData = GetViewData( pLBoxEntry ); if( pViewData ) @@ -766,10 +765,8 @@ void CustomAnimationList::append( CustomAnimationEffectPtr pEffect ) // create an entry for the effect SvTreeListEntry* pEntry = new CustomAnimationListEntry( pEffect ); - pEntry->AddItem(std::unique_ptr<SvLBoxContextBmp>(new SvLBoxContextBmp( - pEntry, 0, Image(), Image(), false))); - pEntry->AddItem(std::unique_ptr<CustomAnimationListEntryItem>( - new CustomAnimationListEntryItem(pEntry, 0, aDescription, pEffect, this))); + pEntry->AddItem(o3tl::make_unique<SvLBoxContextBmp>(Image(), Image(), false)); + pEntry->AddItem(o3tl::make_unique<CustomAnimationListEntryItem>(aDescription, pEffect, this)); if( pParentEntry ) { diff --git a/sd/source/ui/dlg/dlgassim.cxx b/sd/source/ui/dlg/dlgassim.cxx index 20a3dea9ccf4..fe439cd83f8c 100644 --- a/sd/source/ui/dlg/dlgassim.cxx +++ b/sd/source/ui/dlg/dlgassim.cxx @@ -26,6 +26,7 @@ #include <vcl/svapp.hxx> #include <vcl/builderfactory.hxx> +#include <o3tl/make_unique.hxx> #include "svtools/svlbitm.hxx" #include "svtools/treelistentry.hxx" @@ -94,12 +95,9 @@ SvTreeListEntry* SdPageListControl::InsertPage( const OUString& rPageName ) { SvTreeListEntry* pEntry = new SvTreeListEntry; - pEntry->AddItem(std::unique_ptr<SvLBoxButton>(new SvLBoxButton( - pEntry, SvLBoxButtonKind_enabledCheckbox, 0, m_pCheckButton))); - pEntry->AddItem(std::unique_ptr<SvLBoxContextBmp>(new SvLBoxContextBmp( - pEntry, 0, Image(), Image(), false))); // otherwise boom! - pEntry->AddItem(std::unique_ptr<SvLBoxString>(new SvLBoxString( - pEntry, 0, rPageName))); + pEntry->AddItem(o3tl::make_unique<SvLBoxButton>(SvLBoxButtonKind_enabledCheckbox, m_pCheckButton)); + pEntry->AddItem(o3tl::make_unique<SvLBoxContextBmp>(Image(), Image(), false)); // otherwise boom! + pEntry->AddItem(o3tl::make_unique<SvLBoxString>(rPageName)); GetModel()->Insert( pEntry ); @@ -109,12 +107,9 @@ SvTreeListEntry* SdPageListControl::InsertPage( const OUString& rPageName ) void SdPageListControl::InsertTitle( SvTreeListEntry* pParent, const OUString& rTitle ) { SvTreeListEntry* pEntry = new SvTreeListEntry; - pEntry->AddItem(std::unique_ptr<SvLBoxString>(new SvLBoxString( - pEntry, 0, OUString()))); - pEntry->AddItem(std::unique_ptr<SvLBoxContextBmp>(new SvLBoxContextBmp( - pEntry, 0, Image(), Image(), false))); // otherwise boom! - pEntry->AddItem(std::unique_ptr<SvLBoxString>(new SvLBoxString( - pEntry, 0, rTitle))); + pEntry->AddItem(o3tl::make_unique<SvLBoxString>(OUString())); + pEntry->AddItem(o3tl::make_unique<SvLBoxContextBmp>(Image(), Image(), false)); // otherwise boom! + pEntry->AddItem(o3tl::make_unique<SvLBoxString>(rTitle)); GetModel()->Insert( pEntry,pParent ); } diff --git a/sd/source/ui/dlg/sdtreelb.cxx b/sd/source/ui/dlg/sdtreelb.cxx index 726f13271794..0e0babdc0ab2 100644 --- a/sd/source/ui/dlg/sdtreelb.cxx +++ b/sd/source/ui/dlg/sdtreelb.cxx @@ -372,7 +372,7 @@ void SdPageObjsTLB::InitEntry(SvTreeListEntry* pEntry, sal_uInt16 nColToHilite = 1; //0==Bitmap;1=="Spalte1";2=="Spalte2" SvTreeListBox::InitEntry( pEntry, rStr, rImg1, rImg2, eButtonKind ); SvLBoxString& rCol = static_cast<SvLBoxString&>(pEntry->GetItem( nColToHilite )); - pEntry->ReplaceItem(o3tl::make_unique<SvLBoxString>(pEntry, 0, rCol.GetText()), nColToHilite ); + pEntry->ReplaceItem(o3tl::make_unique<SvLBoxString>(rCol.GetText()), nColToHilite ); } void SdPageObjsTLB::SaveExpandedTreeItemState(SvTreeListEntry* pEntry, std::vector<OUString>& vectTreeItem) |