diff options
author | Ocke.Janssen@oracle.com <Ocke.Janssen@oracle.com> | 2011-12-06 01:28:00 +0100 |
---|---|---|
committer | Thorsten Behrens <tbehrens@suse.com> | 2011-12-06 09:39:08 +0100 |
commit | 9753031300bb9bd61bbba2f617900422cdbde1ff (patch) | |
tree | 3145fbd0b22e89a0ae9607e90ac5d58043784d33 /svx/source/gallery2/galbrws1.cxx | |
parent | 0851453849d36e5f58be24316d9bf910ee12faf8 (diff) |
impress210: #i105310# set tooltip for items and some refactoring
# HG changeset patch
# User Ocke.Janssen@oracle.com
# Date 1297164555 -3600
# Node ID 902597eed5414555107034f62583c4ccc2cdfd4b
# Parent 2f0f385e8b25938777bb9fed6a86a2ff43e0b7cd
impress210: #i105310# set tooltip for items and some refactoring
Diffstat (limited to 'svx/source/gallery2/galbrws1.cxx')
-rw-r--r-- | svx/source/gallery2/galbrws1.cxx | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/svx/source/gallery2/galbrws1.cxx b/svx/source/gallery2/galbrws1.cxx index 4c50608b0369..fc20022bcf93 100644 --- a/svx/source/gallery2/galbrws1.cxx +++ b/svx/source/gallery2/galbrws1.cxx @@ -256,9 +256,8 @@ void GalleryBrowser1::ImplFillExchangeData( const GalleryTheme* pThm, ExchangeDa // ----------------------------------------------------------------------------- -::std::vector< sal_uInt16 > GalleryBrowser1::ImplGetExecuteVector() +void GalleryBrowser1::ImplGetExecuteVector(::std::vector< sal_uInt16 >& o_aExec) { - ::std::vector< sal_uInt16 > aExecVector; GalleryTheme* pTheme = mpGallery->AcquireTheme( GetSelectedTheme(), *this ); if( pTheme ) @@ -282,23 +281,21 @@ void GalleryBrowser1::ImplFillExchangeData( const GalleryTheme* pThm, ExchangeDa bUpdateAllowed = bRenameAllowed = bRemoveAllowed = sal_True; if( bUpdateAllowed && pTheme->GetObjectCount() ) - aExecVector.push_back( MN_ACTUALIZE ); + o_aExec.push_back( MN_ACTUALIZE ); if( bRenameAllowed ) - aExecVector.push_back( MN_RENAME ); + o_aExec.push_back( MN_RENAME ); if( bRemoveAllowed ) - aExecVector.push_back( MN_DELETE ); + o_aExec.push_back( MN_DELETE ); if( bIdDialog && !pTheme->IsReadOnly() && !pTheme->IsImported() ) - aExecVector.push_back( MN_ASSIGN_ID ); + o_aExec.push_back( MN_ASSIGN_ID ); - aExecVector.push_back( MN_PROPERTIES ); + o_aExec.push_back( MN_PROPERTIES ); mpGallery->ReleaseTheme( pTheme, *this ); } - - return aExecVector; } // ----------------------------------------------------------------------------- @@ -585,7 +582,8 @@ sal_Bool GalleryBrowser1::KeyInput( const KeyEvent& rKEvt, Window* pWindow ) if( !bRet ) { - ::std::vector< sal_uInt16 > aExecVector( ImplGetExecuteVector() ); + ::std::vector< sal_uInt16 > aExecVector; + ImplGetExecuteVector(aExecVector); sal_uInt16 nExecuteId = 0; sal_Bool bMod1 = rKEvt.GetKeyCode().IsMod1(); @@ -649,9 +647,10 @@ sal_Bool GalleryBrowser1::KeyInput( const KeyEvent& rKEvt, Window* pWindow ) IMPL_LINK( GalleryBrowser1, ShowContextMenuHdl, void*, EMPTYARG ) { - ::std::vector< sal_uInt16 > aExecVector( ImplGetExecuteVector() ); + ::std::vector< sal_uInt16 > aExecVector; + ImplGetExecuteVector(aExecVector); - if( aExecVector.size() ) + if( !aExecVector.empty() ) { PopupMenu aMenu( GAL_RESID( RID_SVXMN_GALLERY1 ) ); |