tdf#150278 sfx2: use provided aInfo, not factory

This continues the revolution from tdf#81293 that was done
for the MOD section of this function in 7.4.
It looks like the same thing needs to be done for APP.

Prior to this commit, opening up the same form control
property dialog always opened up to the same initial tab,
regardless of the last-used-tab. ONLY of document reload
would the last-used-tab come into play.

Now it always opens up immediately tot he last-used-tab.

This is full fix for SAL_USE_VCLPLUGIN=gen.
gtk3 needs an additional fix so it doesn't follow the
second-last-used-tab instead.

Change-Id: Ie7c13cfb48de87c4ab595460680f4306e8feaac7
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138002
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
This commit is contained in:
Justin Luth 2022-08-08 14:13:37 -04:00 committed by Noel Grandin
parent 9bfc9c3f41
commit 6161b951c2

View file

@ -211,12 +211,11 @@ std::unique_ptr<SfxChildWindow> SfxChildWindow::CreateChildWindow( sal_uInt16 nI
pFact = pApp->GetChildWinFactoryById(nId);
if ( pFact )
{
SfxChildWinInfo& rFactInfo = pFact->aInfo;
if ( rInfo.bVisible )
{
if ( pBindings )
pBindings->ENTERREGISTRATIONS();
SfxChildWinInfo aInfo = rFactInfo;
SfxChildWinInfo aInfo = rInfo;
Application::SetSystemWindowMode( SystemWindowFlags::NOAUTOMODE );
pChild = pFact->pCtor( pParent, nId, pBindings, &aInfo );
Application::SetSystemWindowMode( nOldMode );