sd/source/ui/annotations/AnnotationPopup.cxx |    7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

New commits:
commit 45d8c51610ce8e8989961135249af0b89544c094
Author:     Tomaž Vajngerl <tomaz.vajng...@collabora.co.uk>
AuthorDate: Sat Jul 13 23:49:48 2024 +0900
Commit:     Tomaž Vajngerl <qui...@gmail.com>
CommitDate: Sun Jul 14 05:20:04 2024 +0200

    annot: simplifx getting the proper window for popup
    
    Change-Id: Ic9e01d57137ddfbb6f4ec741a275b579741675a4
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/170428
    Tested-by: Jenkins
    Reviewed-by: Tomaž Vajngerl <qui...@gmail.com>

diff --git a/sd/source/ui/annotations/AnnotationPopup.cxx 
b/sd/source/ui/annotations/AnnotationPopup.cxx
index 068d48796302..491f77a7d1aa 100644
--- a/sd/source/ui/annotations/AnnotationPopup.cxx
+++ b/sd/source/ui/annotations/AnnotationPopup.cxx
@@ -74,14 +74,9 @@ void AnnotationPopup::openPopup()
     if (!pViewShell)
         return;
 
-    auto* pView = pViewShell->GetView();
-    if (!pView)
-        return;
-
     if (!mpAnnotationWindow)
     {
-        OutputDevice* pOut = pView->GetFirstOutputDevice();
-        vcl::Window* pWindow = pOut ? pOut->GetOwnerWindow() : nullptr;
+        vcl::Window* pWindow = pViewShell->GetActiveWindow();
         if (pWindow)
         {
             auto aRealPosition2D = mxAnnotation->getPosition();

Reply via email to