[Libreoffice-commits] core.git: Branch 'distro/collabora/cp-6.4' - sw/source
Tor Lillqvist (via logerrit)
logerrit at kemper.freedesktop.org
Wed Jun 10 19:11:22 UTC 2020
sw/source/uibase/shells/basesh.cxx | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
New commits:
commit b6e89538f1d289f521f29736f35c72a1c075e671
Author: Tor Lillqvist <tml at collabora.com>
AuthorDate: Wed Jun 10 17:41:57 2020 +0300
Commit: Andras Timar <andras.timar at collabora.com>
CommitDate: Wed Jun 10 21:10:49 2020 +0200
Fix crash for Table > Insert Table... in Writer and also fix related UITest
Make the code in SwBaseShell::InsertTable be like in master.
Presumably it works correctly?
This also fixes at least UITest_writer_tests.
Change-Id: Ieea0a3d52318055f1ab1e6029038a32ccc597cd3
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/96052
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Andras Timar <andras.timar at collabora.com>
diff --git a/sw/source/uibase/shells/basesh.cxx b/sw/source/uibase/shells/basesh.cxx
index 44f5f0a53b38..d06c3db27483 100644
--- a/sw/source/uibase/shells/basesh.cxx
+++ b/sw/source/uibase/shells/basesh.cxx
@@ -2776,7 +2776,7 @@ void SwBaseShell::InsertTable( SfxRequest& _rRequest )
SwInsertTableOptions aInsTableOptsIn( SwInsertTableFlags::All, 1 );
OUString aTableNameIn;
OUString aAutoNameIn;
- std::unique_ptr<SwTableAutoFormat> pTAFormatIn = nullptr;
+ std::unique_ptr<SwTableAutoFormat> pTAFormatIn;
if( pArgs && pArgs->Count() >= 2 )
{
@@ -2826,7 +2826,7 @@ void SwBaseShell::InsertTable( SfxRequest& _rRequest )
std::shared_ptr<weld::DialogController> pDialogController(pAbstractDialog->getDialogController());
weld::DialogController::runAsync(pDialogController,
- [pAbstractDialog, &rSh, &rTempView, aTableNameIn, nRowsIn, nColsIn, aInsTableOptsIn, aAutoNameIn, &pTAFormatIn] (sal_Int32 nResult) {
+ [pAbstractDialog, &rSh, &rTempView, aTableNameIn, nRowsIn, nColsIn, aInsTableOptsIn, aAutoNameIn] (sal_Int32 nResult) {
if( RET_OK == nResult )
{
sal_uInt16 nCols = nColsIn;
@@ -2834,12 +2834,13 @@ void SwBaseShell::InsertTable( SfxRequest& _rRequest )
SwInsertTableOptions aInsTableOpts = aInsTableOptsIn;
OUString aTableName = aTableNameIn;
OUString aAutoName = aAutoNameIn;
+ std::unique_ptr<SwTableAutoFormat> pTAFormat;
- pAbstractDialog->GetValues( aTableName, nRows, nCols, aInsTableOpts, aAutoName, pTAFormatIn );
+ pAbstractDialog->GetValues( aTableName, nRows, nCols, aInsTableOpts, aAutoName, pTAFormat );
if( nCols && nRows )
{
- InsertTableImpl( rSh, rTempView, aTableName, nRows, nCols, aInsTableOpts, aAutoName, pTAFormatIn );
+ InsertTableImpl( rSh, rTempView, aTableName, nRows, nCols, aInsTableOpts, aAutoName, pTAFormat );
EndUndo(rSh);
}
}
More information about the Libreoffice-commits
mailing list