summaryrefslogtreecommitdiff
path: root/sc/source/ui/drawfunc
diff options
context:
space:
mode:
authorNoel Power <noel.power@novell.com>2012-08-01 18:25:32 +0100
committerNoel Power <noel.power@novell.com>2012-08-01 18:47:50 +0100
commit3514df0f78c6cce2cc618e1c7c2728c759342bce (patch)
tree2112bee815833d03c362c7c58a5bafbd2faaedc3 /sc/source/ui/drawfunc
parent13dc61da882e1e5800665f027894d1885c42def7 (diff)
add TabRatio api and detect macro at group shape fixes bnc#770708
Change-Id: I73eb612edaba21aa5bb07577b42bd31f8de2dd2a
Diffstat (limited to 'sc/source/ui/drawfunc')
-rw-r--r--sc/source/ui/drawfunc/fusel.cxx17
1 files changed, 10 insertions, 7 deletions
diff --git a/sc/source/ui/drawfunc/fusel.cxx b/sc/source/ui/drawfunc/fusel.cxx
index d9fedb4cea18..7665bf692b2d 100644
--- a/sc/source/ui/drawfunc/fusel.cxx
+++ b/sc/source/ui/drawfunc/fusel.cxx
@@ -186,19 +186,22 @@ sal_Bool FuSelection::MouseButtonDown(const MouseEvent& rMEvt)
// associated with the clicked object is used only
// additionally you can also select a macro in Excel for a grouped
- // objects and this results in the macro being set for the elements
- // in the group and no macro is exported for the group
-
+ // objects and this *usually* results in the macro being set
+ // for the elements in the group and no macro is exported
+ // for the group itself ( this however is not always true )
// if a macro and hlink are defined favour the hlink
-
// If a group object has no hyperlink use the hyperlink of the
// object clicked
if ( pObj->IsGroupObject() )
{
- SdrObject* pHit = NULL;
- if ( pView->PickObj(aMDPos, pView->getHitTolLog(), pHit, pPV, SDRSEARCH_DEEP ) )
- pObj = pHit;
+ ScMacroInfo* pTmpInfo = ScDrawLayer::GetMacroInfo( pObj );
+ if ( !pTmpInfo || pTmpInfo->GetMacro().isEmpty() )
+ {
+ SdrObject* pHit = NULL;
+ if ( pView->PickObj(aMDPos, pView->getHitTolLog(), pHit, pPV, SDRSEARCH_DEEP ) )
+ pObj = pHit;
+ }
}
ScMacroInfo* pInfo = ScDrawLayer::GetMacroInfo( pObj, true );