[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - vcl/jsdialog
merttumer (via logerrit)
logerrit at kemper.freedesktop.org
Tue Jun 8 08:01:21 UTC 2021
vcl/jsdialog/executor.cxx | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
New commits:
commit cb7a97c6ecf0bc1fbbf8a8b3494ed581cb9fb310
Author: merttumer <mert.tumer at collabora.com>
AuthorDate: Mon Jun 7 20:16:50 2021 +0300
Commit: Mert Tumer <mert.tumer at collabora.com>
CommitDate: Tue Jun 8 09:58:41 2021 +0200
Fix click on the drawing area of CSV dialog
Change-Id: I8c13698b5e9e2e9c8869aa9094ce93c38bf2276f
Signed-off-by: merttumer <mert.tumer at collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/116796
Reviewed-by: Szymon Kłos <szymon.klos at collabora.com>
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
diff --git a/vcl/jsdialog/executor.cxx b/vcl/jsdialog/executor.cxx
index 4ce9b50e0364..4ee9865e5437 100644
--- a/vcl/jsdialog/executor.cxx
+++ b/vcl/jsdialog/executor.cxx
@@ -157,7 +157,11 @@ bool ExecuteAction(sal_uInt64 nWindowId, const OString& rWidget, StringMap& rDat
{
double posX = std::atof(clickPosX.getStr());
double posY = std::atof(clickPosY.getStr());
- Size size = pArea->get_size_request();
+ OutputDevice& rRefDevice = pArea->get_ref_device();
+ // We send OutPutSize for the drawing area bitmap
+ // get_size_request is not necessarily updated
+ // therefore it may be incorrect.
+ Size size = rRefDevice.GetOutputSize();
posX = posX * size.Width();
posY = posY * size.Height();
LOKTrigger::trigger_click(*pArea, Point(posX, posY));
More information about the Libreoffice-commits
mailing list