summaryrefslogtreecommitdiff
path: root/extensions
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2021-07-16 15:53:00 +0100
committerMichael Stahl <michael.stahl@allotropia.de>2021-08-16 12:07:22 +0200
commit998005696249053b86730efaed220eb52711e688 (patch)
treedab4acab722c788fc69c209e8c233bbb770b919a /extensions
parent420fa261a1bb5db9c6367cd4bbf9984c79b296cc (diff)
Related: tdf#143357 set blank label for no date
instead of current system date Change-Id: Ic504b34990a8ea5151ec653de2db860c1cd4b8ba Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119079 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com> (cherry picked from commit ecf901685ac0c6c7b27b81096bea96cdc3d2c2ca) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/120430 Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Diffstat (limited to 'extensions')
-rw-r--r--extensions/source/propctrlr/standardcontrol.cxx7
1 files changed, 5 insertions, 2 deletions
diff --git a/extensions/source/propctrlr/standardcontrol.cxx b/extensions/source/propctrlr/standardcontrol.cxx
index 26219f8a79af..ef2645a635a1 100644
--- a/extensions/source/propctrlr/standardcontrol.cxx
+++ b/extensions/source/propctrlr/standardcontrol.cxx
@@ -97,15 +97,18 @@ namespace pcr
void SAL_CALL ODateControl::setValue( const Any& _rValue )
{
+ SvtCalendarBox* pCalendarBox = getTypedControlWindow();
+
util::Date aUNODate;
if ( !( _rValue >>= aUNODate ) )
{
- getTypedControlWindow()->set_date(::Date(::Date::SYSTEM));
+ pCalendarBox->set_date(::Date(::Date::SYSTEM));
+ pCalendarBox->set_label("");
}
else
{
::Date aDate( aUNODate.Day, aUNODate.Month, aUNODate.Year );
- getTypedControlWindow()->set_date(aDate);
+ pCalendarBox->set_date(aDate);
}
}