summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMaxim Monastirsky <momonasmon@gmail.com>2016-04-04 13:20:39 +0300
committerMaxim Monastirsky <momonasmon@gmail.com>2016-04-04 15:37:10 +0300
commit3a93a75fe1d89520692edc2f615b1c8d5cd0c52b (patch)
tree278e0358476282d5c7d2a28d9c2afd4d08c26c3e /sw
parent804209f6b37babf339874d599db7d03ce594fe4e (diff)
Restore some erroneously removed code
Change-Id: Icc6fe929b86d494099bd1b7fafd5fc4c2787dbbd
Diffstat (limited to 'sw')
-rw-r--r--sw/source/uibase/docvw/SidebarTxtControl.cxx12
1 files changed, 11 insertions, 1 deletions
diff --git a/sw/source/uibase/docvw/SidebarTxtControl.cxx b/sw/source/uibase/docvw/SidebarTxtControl.cxx
index 51c2c040e909..c997b4a843f8 100644
--- a/sw/source/uibase/docvw/SidebarTxtControl.cxx
+++ b/sw/source/uibase/docvw/SidebarTxtControl.cxx
@@ -376,7 +376,17 @@ void SidebarTextControl::Command( const CommandEvent& rCEvt )
GetTextView()->ExecuteSpellPopup(rCEvt.GetMousePosPixel(),&aLink);
}
else
- SfxDispatcher::ExecutePopup(this, &rCEvt.GetMousePosPixel());
+ {
+ Point aPos;
+ if (rCEvt.IsMouseEvent())
+ aPos = rCEvt.GetMousePosPixel();
+ else
+ {
+ const Size aSize = GetSizePixel();
+ aPos = Point( aSize.getWidth()/2, aSize.getHeight()/2 );
+ }
+ SfxDispatcher::ExecutePopup(this, &aPos);
+ }
}
else
if (rCEvt.GetCommand() == CommandEventId::Wheel)