diff options
author | Dennis Francis <dennis.francis@collabora.com> | 2021-11-24 17:44:30 +0530 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2022-01-11 11:18:08 +0100 |
commit | be329f241ee4953a039ab4bb22f46a5ac0ad5859 (patch) | |
tree | fba746890bc3e1057bc9d9dfc4c500e1e950a2af /sc | |
parent | lokCalcRTL: fix autofilter button hit detection (diff) | |
download | core-be329f241ee4953a039ab4bb22f46a5ac0ad5859.tar.gz core-be329f241ee4953a039ab4bb22f46a5ac0ad5859.zip |
lokCalcRTL: fix autofilter popup position
Change-Id: Iecf41c286e28f849f77da47a0c5f73cbbc02986a
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/ui/cctrl/checklistmenu.cxx | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx index efd8688dc649..c80c896f832f 100644 --- a/sc/source/ui/cctrl/checklistmenu.cxx +++ b/sc/source/ui/cctrl/checklistmenu.cxx @@ -1381,8 +1381,17 @@ void ScCheckListMenuControl::launch(const tools::Rectangle& rRect) if (maConfig.mbRTL) { // In RTL mode, the logical "left" is visual "right". - tools::Long nLeft = aRect.Left() - aRect.GetWidth(); - aRect.SetLeft( nLeft ); + if (!comphelper::LibreOfficeKit::isActive()) + { + tools::Long nLeft = aRect.Left() - aRect.GetWidth(); + aRect.SetLeft( nLeft ); + } + else + { + // in LOK mode, rRect is in document pixel coordinates, so width has to be added + // to place the popup next to the (visual) left aligned button. + aRect.Move(aRect.GetWidth(), 0); + } } else if (mnWndWidth < aRect.GetWidth()) { |