From 675db4db926a09024df57ae8f9be457662393757 Mon Sep 17 00:00:00 2001
From: Miklos Vajna <vmiklos@collabora.co.uk>
Date: Thu, 22 Oct 2015 14:15:14 +0200
Subject: [PATCH 237/398] sd: implement vcl::ITiledRenderable::getWindow()
(cherry picked from commit 8522948ba2f30fb703d4725086d30d9aa2a0cf4c)
Change-Id: I8bc7316d9304d9e764ee846fe3af34599bf6fc35
---
sd/source/ui/inc/unomodel.hxx | 4 +++-
sd/source/ui/unoidl/unomodel.cxx | 11 +++++++++++
2 files changed, 14 insertions(+), 1 deletion(-)
diff --git a/sd/source/ui/inc/unomodel.hxx b/sd/source/ui/inc/unomodel.hxx
index 4d7314875f0b..a24f774e2fc9 100644
--- a/sd/source/ui/inc/unomodel.hxx
+++ b/sd/source/ui/inc/unomodel.hxx
@@ -257,7 +257,9 @@ public:
/// @see vcl::ITiledRenderable::setGraphicSelection().
virtual void setGraphicSelection(int nType, int nX, int nY) SAL_OVERRIDE;
/// @see lok::Document::resetSelection().
- virtual void resetSelection() SAL_OVERRIDE;
+ virtual void resetSelection() override;
+ /// @see vcl::ITiledRenderable::getWindow().
+ virtual vcl::Window* getWindow() override;
// XComponent
diff --git a/sd/source/ui/unoidl/unomodel.cxx b/sd/source/ui/unoidl/unomodel.cxx
index 6ae01a28efac..1628a18df296 100644
--- a/sd/source/ui/unoidl/unomodel.cxx
+++ b/sd/source/ui/unoidl/unomodel.cxx
@@ -2539,6 +2539,17 @@ void SdXImpressDocument::resetSelection()
pSdrView->UnmarkAll();
}
+vcl::Window* SdXImpressDocument::getWindow()
+{
+ SolarMutexGuard aGuard;
+
+ DrawViewShell* pViewShell = GetViewShell();
+ if (!pViewShell)
+ return 0;
+
+ return pViewShell->GetActiveWindow();
+}
+
uno::Reference< i18n::XForbiddenCharacters > SdXImpressDocument::getForbiddenCharsTable()
{
uno::Reference< i18n::XForbiddenCharacters > xForb(mxForbidenCharacters);
--
2.12.0