From 5e2bd2bb4c1a2f8a5467009b4ab7007401a14446 Mon Sep 17 00:00:00 2001 From: Rashesh Date: Thu, 26 Sep 2024 16:39:55 +0530 Subject: cool#10115 sc: enable ScPosWnd for lokit with jsdialog MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change-Id: I18829c48a2495e3aa31af83970c8c1c4791a170a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/173987 Tested-by: Jenkins CollaboraOffice Reviewed-by: Szymon Kłos (cherry picked from commit 9ffc274bbc414d1e98313af804386861beeff9bf) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/177645 Tested-by: Jenkins --- sc/source/ui/app/inputwin.cxx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'sc/source/ui/app/inputwin.cxx') diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx index b70a2d21aa90..f9d76b365959 100644 --- a/sc/source/ui/app/inputwin.cxx +++ b/sc/source/ui/app/inputwin.cxx @@ -144,7 +144,7 @@ SfxChildWinInfo ScInputWindowWrapper::GetInfo() const } -static VclPtr lcl_chooseRuntimeImpl( vcl::Window* pParent, const SfxBindings* pBind ) +static ScTabViewShell* lcl_chooseRuntimeImpl( const SfxBindings* pBind ) { ScTabViewShell* pViewSh = nullptr; SfxDispatcher* pDisp = pBind->GetDispatcher(); @@ -154,15 +154,14 @@ static VclPtr lcl_chooseRuntimeImpl( vcl::Window* pParent, cons if ( pViewFrm ) pViewSh = dynamic_cast( pViewFrm->GetViewShell() ); } - - return VclPtr::Create( pParent, pViewSh ); + return pViewSh; } ScInputWindow::ScInputWindow( vcl::Window* pParent, const SfxBindings* pBind ) : // With WB_CLIPCHILDREN otherwise we get flickering ToolBox ( pParent, WinBits(WB_CLIPCHILDREN | WB_BORDER | WB_NOSHADOW) ), - aWndPos ( !comphelper::LibreOfficeKit::isActive() ? VclPtr::Create(this) : nullptr ), - mxTextWindow ( lcl_chooseRuntimeImpl( this, pBind ) ), + aWndPos ( VclPtr::Create( this, lcl_chooseRuntimeImpl(pBind)) ), + mxTextWindow ( VclPtr::Create( this, lcl_chooseRuntimeImpl(pBind)) ), pInputHdl ( nullptr ), mpViewShell ( nullptr ), mnMaxY (0), @@ -2253,8 +2252,9 @@ void ScTextWnd::TextGrabFocus() } // Position window -ScPosWnd::ScPosWnd(vcl::Window* pParent) - : InterimItemWindow(pParent, u"modules/scalc/ui/posbox.ui"_ustr, u"PosBox"_ustr) +ScPosWnd::ScPosWnd(vcl::Window* pParent, ScTabViewShell* pViewShell) + : InterimItemWindow(pParent, u"modules/scalc/ui/posbox.ui"_ustr, u"PosBox"_ustr, false, + reinterpret_cast(pViewShell)) , m_xWidget(m_xBuilder->weld_combo_box(u"pos_window"_ustr)) , m_nAsyncGetFocusId(nullptr) , nTipVisible(nullptr) -- cgit