From 346cda683763aa352cf67a035340e48133790f7f Mon Sep 17 00:00:00 2001 From: NickWingate Date: Fri, 12 Aug 2022 09:48:18 +0100 Subject: Fix opening duration custom property shows text MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Before saving a duration custom property and then closing and opening file props wouldn't show the duration type and value and instead blank text Signed-off-by: NickWingate Change-Id: Ie6536dd75151db40f335985c1ce92236ce77ddc2 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/138180 Reviewed-by: Szymon Kłos Tested-by: Jenkins CollaboraOffice Reviewed-on: https://gerrit.libreoffice.org/c/core/+/142986 Tested-by: Jenkins --- sfx2/source/dialog/dinfdlg.cxx | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'sfx2') diff --git a/sfx2/source/dialog/dinfdlg.cxx b/sfx2/source/dialog/dinfdlg.cxx index 9cb911c469e0..eec2e4ca980d 100644 --- a/sfx2/source/dialog/dinfdlg.cxx +++ b/sfx2/source/dialog/dinfdlg.cxx @@ -1796,17 +1796,14 @@ void CustomPropertiesWindow::ReloadLinesContent() pLine->m_xDurationField->SetDuration(aTmpDuration); } - if (nType != Custom_Type_Duration) + if (Custom_Type_Boolean == nType) { - if (Custom_Type_Boolean == nType) - { - if (bTmpValue) - pLine->m_xYesNoButton->CheckYes(); - else - pLine->m_xYesNoButton->CheckNo(); - } - pLine->m_xTypeBox->set_active_id(OUString::number(nType)); + if (bTmpValue) + pLine->m_xYesNoButton->CheckYes(); + else + pLine->m_xYesNoButton->CheckNo(); } + pLine->m_xTypeBox->set_active_id(OUString::number(nType)); pLine->DoTypeHdl(*pLine->m_xTypeBox); } -- cgit