summaryrefslogtreecommitdiffstats
path: root/sfx2
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-11-24 14:51:03 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-11-24 16:36:01 +0000
commitfdba97bb3940b2763167510fab91df4b33293115 (patch)
treeb947a7fa2014ae0b26cedb46cb789b28318b4559 /sfx2
parentso SfxInterface::GetObjectBarName is now unused (diff)
downloadcore-fdba97bb3940b2763167510fab91df4b33293115.tar.gz
core-fdba97bb3940b2763167510fab91df4b33293115.zip
so SfxObjectUI_Impl pName is only set, never read
Change-Id: If920c1d32c457e339c13010a19670c917de9c3aa
Diffstat (limited to 'sfx2')
-rw-r--r--sfx2/source/control/objface.cxx27
1 files changed, 1 insertions, 26 deletions
diff --git a/sfx2/source/control/objface.cxx b/sfx2/source/control/objface.cxx
index 8f603c45d9e1..e13f0d9ce65d 100644
--- a/sfx2/source/control/objface.cxx
+++ b/sfx2/source/control/objface.cxx
@@ -378,23 +378,18 @@ const SfxSlot* SfxInterface::GetRealSlot( sal_uInt16 nSlotId ) const
return pSlot->pLinkedSlot;
}
-
-
void SfxInterface::RegisterPopupMenu( const ResId& rResId )
{
pImpData->aPopupRes = rResId;
}
-
-
void SfxInterface::RegisterObjectBar( sal_uInt16 nPos, const ResId& rResId,
const OUString *pStr )
{
RegisterObjectBar( nPos, rResId, 0UL, pStr );
}
-
void SfxInterface::RegisterObjectBar( sal_uInt16 nPos, const ResId& rResId, sal_uInt32 nFeature, const OUString *pStr )
{
SfxObjectUI_Impl* pUI = CreateObjectBarUI_Impl( nPos, rResId, nFeature, pStr );
@@ -407,24 +402,7 @@ SfxObjectUI_Impl* CreateObjectBarUI_Impl( sal_uInt16 nPos, const ResId& rResId,
if ((nPos & SFX_VISIBILITY_MASK) == 0)
nPos |= SFX_VISIBILITY_STANDARD;
- SfxObjectUI_Impl* pUI = new SfxObjectUI_Impl(nPos, rResId, true, nFeature);
-
- if (pStr == 0)
- {
- ResId aResId(rResId);
- aResId.SetRT(RSC_STRING);
- aResId.SetResMgr(rResId.GetResMgr());
- if( ! aResId.GetResMgr() )
- aResId.SetResMgr( SfxApplication::GetOrCreate()->GetOffResManager_Impl() );
- if ( !aResId.GetResMgr() || !aResId.GetResMgr()->IsAvailable(aResId) )
- pUI->pName = new OUString ("NoName");
- else
- pUI->pName = new OUString(aResId.toString());
- }
- else
- pUI->pName = new OUString(*pStr);
-
- return pUI;
+ return new SfxObjectUI_Impl(nPos, rResId, true, nFeature);
}
const ResId& SfxInterface::GetObjectBarResId( sal_uInt16 nNo ) const
@@ -446,9 +424,6 @@ const ResId& SfxInterface::GetObjectBarResId( sal_uInt16 nNo ) const
return pImpData->aObjectBars[nNo]->aResId;
}
-
-
-
sal_uInt16 SfxInterface::GetObjectBarPos( sal_uInt16 nNo ) const
{
bool bGenoType = (pGenoType != 0 && !pGenoType->HasName());