diff options
author | Marco Cecchetti <marco.cecchetti@collabora.com> | 2023-03-09 20:49:46 +0100 |
---|---|---|
committer | Marco Cecchetti <marco.cecchetti@collabora.com> | 2023-03-10 17:06:02 +0000 |
commit | 4eae3fcae0bcc3aafa5b51d80ffca7e4d539f97a (patch) | |
tree | 8143894641b11525c5bd9b61a10873620c75142c /vcl | |
parent | eaa5f54dd1d64f314379a34277a19503eb5b38df (diff) |
lok: some tunneled dialog control was not invalidated correctly
This patch fixes a regression for commit:
"lok: form controls: rendering and mouse event forwarding"
Change-Id: Iffb0757834a884a6c86206221660da2a24bdff17
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148564
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Andras Timar <andras.timar@collabora.com>
(cherry picked from commit 7ed760c4564834ec61ceb91f681dfc6daa1be4bd)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148621
Tested-by: Jenkins
Reviewed-by: Marco Cecchetti <marco.cecchetti@collabora.com>
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/control/ctrl.cxx | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/vcl/source/control/ctrl.cxx b/vcl/source/control/ctrl.cxx index 46d1507eb40b..7a0b27982956 100644 --- a/vcl/source/control/ctrl.cxx +++ b/vcl/source/control/ctrl.cxx @@ -497,16 +497,17 @@ Control::GetUnzoomedControlPointFont() const void Control::LogicInvalidate(const tools::Rectangle* pRectangle) { - // avoid endless paint/invalidate loop in Impress - if (comphelper::LibreOfficeKit::isTiledPainting()) - return; - VclPtr<vcl::Window> pParent = GetParentWithLOKNotifier(); - if (!pParent) + if (!pParent || !dynamic_cast<vcl::DocWindow*>(GetParent())) + { + // if control doesn't belong to a DocWindow, the overriden base class + // method has to be invoked + Window::LogicInvalidate(pRectangle); return; + } - // invalidate only controls that belong to a DocWindow - if (!dynamic_cast<vcl::DocWindow*>(GetParent())) + // avoid endless paint/invalidate loop in Impress + if (comphelper::LibreOfficeKit::isTiledPainting()) return; tools::Rectangle aResultRectangle; |