summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJürgen Schmidt <jsc@apache.org>2013-03-20 14:15:58 +0000
committerCaolán McNamara <caolanm@redhat.com>2013-05-23 11:55:26 +0100
commit5e059c1ee53b6be058f66a7c43af0e75f3cadfa1 (patch)
tree673236fae4643e65b3fa19962a76ef52bde01cfb
parent1959113eac6bb23310883c974ac40cba6f222493 (diff)
Resolves: #i121731# extend XSmartTagAction->getActionCount...
with additional parameter to increase flexibility of context menus Patch by: Kai Labusch Review by: arielch, jsc (cherry picked from commit 5898e201ae8bbc1203bf24629a389f8f3b3e02ee) Conflicts: svx/source/mnuctrls/SmartTagCtl.cxx Change-Id: I91d50b94657c29db289864863ee752d4ce45db6c
-rw-r--r--offapi/com/sun/star/smarttags/XSmartTagAction.idl9
-rw-r--r--svx/source/mnuctrls/SmartTagCtl.cxx4
-rw-r--r--sw/source/ui/smartmenu/stmenu.cxx2
3 files changed, 8 insertions, 7 deletions
diff --git a/offapi/com/sun/star/smarttags/XSmartTagAction.idl b/offapi/com/sun/star/smarttags/XSmartTagAction.idl
index 3f85469e3b76..005eb6f25db4 100644
--- a/offapi/com/sun/star/smarttags/XSmartTagAction.idl
+++ b/offapi/com/sun/star/smarttags/XSmartTagAction.idl
@@ -82,7 +82,7 @@ interface XSmartTagAction: com::sun::star::lang::XInitialization
@throws com::sun::star::lang::IndexOutOfBoundsException
if nSmartTagIndex is greater than SmartTagCount.
*/
- string getSmartTagName( [in] long nSmartTagIndex )
+ string getSmartTagName( [in] long nSmartTagIndex)
raises( com::sun::star::lang::IndexOutOfBoundsException );
@@ -104,7 +104,7 @@ interface XSmartTagAction: com::sun::star::lang::XInitialization
if nSmartTagIndex is greater than SmartTagCount
*/
string getSmartTagCaption( [in] long nSmartTagIndex,
- [in] ::com::sun::star::lang::Locale aLocale )
+ [in] ::com::sun::star::lang::Locale aLocale)
raises( com::sun::star::lang::IndexOutOfBoundsException );
@@ -123,7 +123,8 @@ interface XSmartTagAction: com::sun::star::lang::XInitialization
type.
*/
long getActionCount( [in] string aSmartTagName,
- [in] com::sun::star::frame::XController xController );
+ [in] com::sun::star::frame::XController xController,
+ [in] com::sun::star::container::XStringKeyMap xProperties);
/** obtains a unique integer identifier for an action.
@@ -210,7 +211,7 @@ interface XSmartTagAction: com::sun::star::lang::XInitialization
if the ActionID is not recognized.
*/
string getActionNameFromID( [in] long nActionID,
- [in] com::sun::star::frame::XController xController )
+ [in] com::sun::star::frame::XController xController)
raises( com::sun::star::lang::IllegalArgumentException );
diff --git a/svx/source/mnuctrls/SmartTagCtl.cxx b/svx/source/mnuctrls/SmartTagCtl.cxx
index 4f0f3fe523b8..8e9b05349646 100644
--- a/svx/source/mnuctrls/SmartTagCtl.cxx
+++ b/svx/source/mnuctrls/SmartTagCtl.cxx
@@ -92,7 +92,7 @@ void SvxSmartTagsControl::FillMenu()
const sal_Int32 nSmartTagIndex = rActionIndices[0];
const OUString aSmartTagType = xAction->getSmartTagName( nSmartTagIndex );
- const OUString aSmartTagCaption = xAction->getSmartTagCaption( nSmartTagIndex, rLocale );
+ const OUString aSmartTagCaption = xAction->getSmartTagCaption( nSmartTagIndex, rLocale);
// no sub-menus if there's only one smart tag type listed:
PopupMenu* pSbMenu = mpMenu;
@@ -115,7 +115,7 @@ void SvxSmartTagsControl::FillMenu()
{
xAction = rActionComponents[i];
- for ( sal_Int32 k = 0; k < xAction->getActionCount( aSmartTagType, xController ); ++k )
+ for ( sal_Int32 k = 0; k < xAction->getActionCount( aSmartTagType, xController, xSmartTagProperties ); ++k )
{
const sal_uInt32 nActionID = xAction->getActionID( aSmartTagType, k, xController );
OUString aActionCaption = xAction->getActionCaptionFromID( nActionID,
diff --git a/sw/source/ui/smartmenu/stmenu.cxx b/sw/source/ui/smartmenu/stmenu.cxx
index b77f7b660eca..795c91062661 100644
--- a/sw/source/ui/smartmenu/stmenu.cxx
+++ b/sw/source/ui/smartmenu/stmenu.cxx
@@ -104,7 +104,7 @@ SwSmartTagPopup::SwSmartTagPopup( SwView* pSwView,
{
xAction = rActionComponents[i];
- for ( sal_Int32 k = 0; k < xAction->getActionCount( aSmartTagType, xController ); ++k )
+ for ( sal_Int32 k = 0; k < xAction->getActionCount( aSmartTagType, xController, xSmartTagProperties ); ++k )
{
const sal_uInt32 nActionID = xAction->getActionID( aSmartTagType, k, xController );
OUString aActionCaption = xAction->getActionCaptionFromID( nActionID,