include/toolkit/awt/vclxtopwindow.hxx | 7 ++----- toolkit/source/awt/vclxtoolkit.cxx | 4 ++-- toolkit/source/awt/vclxtopwindow.cxx | 12 ++++-------- 3 files changed, 8 insertions(+), 15 deletions(-)
New commits: commit 3814952f0be80afddcfda7f0e65bb602ed75438c Author: Caolán McNamara <caol...@redhat.com> Date: Fri Sep 1 12:06:23 2017 +0100 support XSystemDependentWindowPeer for all toplevel windows Change-Id: Id79fba6956e2a97a10dcec1cab883d3665ef1628 Reviewed-on: https://gerrit.libreoffice.org/41806 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Caolán McNamara <caol...@redhat.com> Tested-by: Caolán McNamara <caol...@redhat.com> diff --git a/include/toolkit/awt/vclxtopwindow.hxx b/include/toolkit/awt/vclxtopwindow.hxx index c56269b4bab5..cc8746ba6ec6 100644 --- a/include/toolkit/awt/vclxtopwindow.hxx +++ b/include/toolkit/awt/vclxtopwindow.hxx @@ -37,9 +37,6 @@ typedef ::cppu::ImplHelper1 < css::awt::XSystemDependentWindowPeer class TOOLKIT_DLLPUBLIC VCLXTopWindow_Base :public VCLXTopWindow_XBase ,public VCLXTopWindow_SBase { -private: - const bool m_bWHWND; - protected: css::uno::Reference< css::awt::XMenuBar> mxMenuBar; @@ -47,7 +44,7 @@ protected: virtual vcl::Window* GetWindowImpl() = 0; virtual ::comphelper::OInterfaceContainerHelper2& GetTopWindowListenersImpl() = 0; - VCLXTopWindow_Base( const bool _bSupportSystemWindowPeer ); + VCLXTopWindow_Base(); public: virtual ~VCLXTopWindow_Base(); @@ -88,7 +85,7 @@ protected: virtual ::comphelper::OInterfaceContainerHelper2& GetTopWindowListenersImpl() override; public: - VCLXTopWindow(bool bWHWND = false); + VCLXTopWindow(); virtual ~VCLXTopWindow() override; // css::uno::XInterface diff --git a/toolkit/source/awt/vclxtoolkit.cxx b/toolkit/source/awt/vclxtoolkit.cxx index 866eb2a4cc2c..9076ae37f259 100644 --- a/toolkit/source/awt/vclxtoolkit.cxx +++ b/toolkit/source/awt/vclxtoolkit.cxx @@ -1163,7 +1163,7 @@ vcl::Window* VCLXToolkit::ImplCreateWindow( VCLXWindow** ppNewComp, pNewWindow = VclPtr<WorkWindow>::Create( pParent, nWinBits ); } - *ppNewComp = new VCLXTopWindow( pNewWindow->GetType() == WindowType::WORKWINDOW ); + *ppNewComp = new VCLXTopWindow(); } else if ( rDescriptor.Type == css::awt::WindowClass_CONTAINER ) { @@ -1406,7 +1406,7 @@ css::uno::Reference< css::awt::XWindowPeer > VCLXToolkit::createSystemChild( con css::uno::Reference< css::awt::XWindowPeer > xPeer; if ( pChildWindow ) { - VCLXTopWindow* pPeer = new VCLXTopWindow(true); + VCLXTopWindow* pPeer = new VCLXTopWindow; SolarMutexGuard aGuard; pPeer->SetWindow( pChildWindow ); xPeer = pPeer; diff --git a/toolkit/source/awt/vclxtopwindow.cxx b/toolkit/source/awt/vclxtopwindow.cxx index 784ff17b3373..fbd00b907937 100644 --- a/toolkit/source/awt/vclxtopwindow.cxx +++ b/toolkit/source/awt/vclxtopwindow.cxx @@ -49,8 +49,7 @@ using ::com::sun::star::uno::Type; using ::com::sun::star::uno::Any; using ::com::sun::star::lang::IndexOutOfBoundsException; -VCLXTopWindow_Base::VCLXTopWindow_Base( const bool _bSupportSystemWindowPeer ) - :m_bWHWND( _bSupportSystemWindowPeer ) +VCLXTopWindow_Base::VCLXTopWindow_Base() { } @@ -62,8 +61,7 @@ Any VCLXTopWindow_Base::queryInterface( const Type & rType ) { css::uno::Any aRet( VCLXTopWindow_XBase::queryInterface( rType ) ); - // do not expose XSystemDependentWindowPeer if we do not have a system window handle - if ( !aRet.hasValue() && m_bWHWND ) + if (!aRet.hasValue()) aRet = VCLXTopWindow_SBase::queryInterface( rType ); return aRet; @@ -72,8 +70,7 @@ Any VCLXTopWindow_Base::queryInterface( const Type & rType ) Sequence< Type > VCLXTopWindow_Base::getTypes() { Sequence< Type > aTypes( VCLXTopWindow_XBase::getTypes() ); - if ( m_bWHWND ) - aTypes = ::comphelper::concatSequences( aTypes, VCLXTopWindow_SBase::getTypes() ); + aTypes = ::comphelper::concatSequences( aTypes, VCLXTopWindow_SBase::getTypes() ); return aTypes; } @@ -249,8 +246,7 @@ void VCLXTopWindow::ImplGetPropertyIds( std::vector< sal_uInt16 > &rIds ) VCLXContainer::ImplGetPropertyIds( rIds ); } -VCLXTopWindow::VCLXTopWindow(bool bWHWND) - : VCLXTopWindow_Base( bWHWND ) +VCLXTopWindow::VCLXTopWindow() { }
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits