[Libreoffice-commits] core.git: sfx2/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Thu Jan 10 13:49:56 UTC 2019
sfx2/source/doc/new.cxx | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
New commits:
commit 888957648d15c60cd5849f8f8c2bdf55a3b78da8
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Thu Jan 10 09:43:51 2019 +0000
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Thu Jan 10 14:49:32 2019 +0100
Resolves: tdf#122611 crash in empty template list
Change-Id: Ifab72f21e92382a3072a35447c6387e1fd405e15
Reviewed-on: https://gerrit.libreoffice.org/66070
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/sfx2/source/doc/new.cxx b/sfx2/source/doc/new.cxx
index d6d45c7f14e5..ed196a0a384d 100644
--- a/sfx2/source/doc/new.cxx
+++ b/sfx2/source/doc/new.cxx
@@ -184,7 +184,8 @@ IMPL_LINK( SfxNewFileDialog, RegionSelect, weld::TreeView&, rBox, void )
for (sal_uInt16 i = 0; i < nCount; ++i)
m_xTemplateLb->append_text(m_aTemplates.GetName(nRegion, i));
m_xTemplateLb->thaw();
- m_xTemplateLb->select(0);
+ if (nCount)
+ m_xTemplateLb->select(0);
TemplateSelect(*m_xTemplateLb);
}
More information about the Libreoffice-commits
mailing list