diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-05-13 10:40:44 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2021-05-13 14:48:24 +0200 |
commit | 32b09faca508ae4aac7e100c98a2fe56d3302eef (patch) | |
tree | df4c3f089cd83b361c3f5133344397d9d888e9b5 /basctl | |
parent | 013a4f1f5c9ea5fb511568c53a7e76d1b365a65d (diff) |
Revert "simplify the vcl<->toolkit connection"
because it introduces a link-time dependency of vcl on toolkit,
and toolkit already depends on vcl
This reverts commit f7a86c5cdf4323c99d26512bf78de7f7c380667d.
Change-Id: Ibdd4f3e8221d70e2abd8fcbda67f85af3ac0396e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/115547
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'basctl')
-rw-r--r-- | basctl/source/accessibility/accessibledialogcontrolshape.cxx | 2 | ||||
-rw-r--r-- | basctl/source/accessibility/accessibledialogwindow.cxx | 2 | ||||
-rw-r--r-- | basctl/source/basicide/baside2.hxx | 2 | ||||
-rw-r--r-- | basctl/source/basicide/baside2b.cxx | 9 | ||||
-rw-r--r-- | basctl/source/basicide/textwindowpeer.cxx | 2 | ||||
-rw-r--r-- | basctl/source/basicide/textwindowpeer.hxx | 9 |
6 files changed, 15 insertions, 11 deletions
diff --git a/basctl/source/accessibility/accessibledialogcontrolshape.cxx b/basctl/source/accessibility/accessibledialogcontrolshape.cxx index b61385f6671a..f885ff4bda1b 100644 --- a/basctl/source/accessibility/accessibledialogcontrolshape.cxx +++ b/basctl/source/accessibility/accessibledialogcontrolshape.cxx @@ -495,7 +495,7 @@ Reference< awt::XFont > AccessibleDialogControlShape::getFont( ) vcl::Window* pWindow = GetWindow(); if ( pWindow ) { - auto xDev = pWindow->GetComponentInterfaceAs<awt::XDevice>(); + Reference< awt::XDevice > xDev( pWindow->GetComponentInterface(), UNO_QUERY ); if ( xDev.is() ) { vcl::Font aFont; diff --git a/basctl/source/accessibility/accessibledialogwindow.cxx b/basctl/source/accessibility/accessibledialogwindow.cxx index b91e48262a73..0b641c8aca5e 100644 --- a/basctl/source/accessibility/accessibledialogwindow.cxx +++ b/basctl/source/accessibility/accessibledialogwindow.cxx @@ -790,7 +790,7 @@ Reference< awt::XFont > AccessibleDialogWindow::getFont( ) Reference< awt::XFont > xFont; if ( m_pDialogWindow ) { - auto xDev = m_pDialogWindow->GetComponentInterfaceAs<awt::XDevice>(); + Reference< awt::XDevice > xDev( m_pDialogWindow->GetComponentInterface(), UNO_QUERY ); if ( xDev.is() ) { vcl::Font aFont; diff --git a/basctl/source/basicide/baside2.hxx b/basctl/source/basicide/baside2.hxx index fd17b340ca54..06045356bccb 100644 --- a/basctl/source/basicide/baside2.hxx +++ b/basctl/source/basicide/baside2.hxx @@ -100,7 +100,7 @@ private: bool bDoSyntaxHighlight; bool bDelayHighlight; - virtual VCLXWindow* GetComponentInterface(bool bCreate = true) override; + virtual css::uno::Reference< css::awt::XWindowPeer > GetComponentInterface(bool bCreate = true) override; CodeCompleteDataCache aCodeCompleteCache; VclPtr<CodeCompleteWindow> pCodeCompleteWnd; OUString GetActualSubName( sal_uLong nLine ); // gets the actual subroutine name according to line number diff --git a/basctl/source/basicide/baside2b.cxx b/basctl/source/basicide/baside2b.cxx index 3168f5090532..ecba2d5fa873 100644 --- a/basctl/source/basicide/baside2b.cxx +++ b/basctl/source/basicide/baside2b.cxx @@ -2040,10 +2040,11 @@ void ComplexEditorWindow::SetLineNumberDisplay(bool b) Resize(); } -VCLXWindow* +uno::Reference< awt::XWindowPeer > EditorWindow::GetComponentInterface(bool bCreate) { - rtl::Reference< VCLXWindow > xPeer = Window::GetComponentInterface(false); + uno::Reference< awt::XWindowPeer > xPeer( + Window::GetComponentInterface(false)); if (!xPeer.is() && bCreate) { // Make sure edit engine and view are available: @@ -2051,9 +2052,9 @@ EditorWindow::GetComponentInterface(bool bCreate) CreateEditEngine(); xPeer = createTextWindowPeer(*GetEditView()); - SetComponentInterface(xPeer.get()); + SetComponentInterface(xPeer); } - return xPeer.get(); + return xPeer; } static sal_uInt32 getCorrectedPropCount(SbxArray* p) diff --git a/basctl/source/basicide/textwindowpeer.cxx b/basctl/source/basicide/textwindowpeer.cxx index cbe9781fce90..fc458453778b 100644 --- a/basctl/source/basicide/textwindowpeer.cxx +++ b/basctl/source/basicide/textwindowpeer.cxx @@ -62,7 +62,7 @@ TextWindowPeer::CreateAccessibleContext() { } -rtl::Reference<VCLXWindow> basctl::createTextWindowPeer( +css::uno::Reference<css::awt::XWindowPeer> basctl::createTextWindowPeer( TextView & view) { return new TextWindowPeer(view); diff --git a/basctl/source/basicide/textwindowpeer.hxx b/basctl/source/basicide/textwindowpeer.hxx index 701c134c3a5f..077ad32cd79f 100644 --- a/basctl/source/basicide/textwindowpeer.hxx +++ b/basctl/source/basicide/textwindowpeer.hxx @@ -21,14 +21,17 @@ #include <sal/config.h> -#include <rtl/ref.hxx> +#include <com/sun/star/uno/Reference.hxx> -class VCLXWindow; +namespace com::sun::star::awt +{ +class XWindowPeer; +} class TextView; namespace basctl { -rtl::Reference<VCLXWindow> createTextWindowPeer(TextView& view); +css::uno::Reference<css::awt::XWindowPeer> createTextWindowPeer(TextView& view); } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |