diff options
author | Lionel Elie Mamane <lionel@mamane.lu> | 2015-07-22 16:25:28 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-07-24 13:39:19 +0000 |
commit | 07ce7182fc7115292aea8f5bd43f4f983c1eb1a3 (patch) | |
tree | 5e5ee7ad2b0f90535353ac4fa0cf63d4f286f9dd | |
parent | update branding for 5.0 (diff) | |
download | core-07ce7182fc7115292aea8f5bd43f4f983c1eb1a3.tar.gz core-07ce7182fc7115292aea8f5bd43f4f983c1eb1a3.zip |
tdf#92725 FormattedField: when model value is NULL, force empty display string
as opposed to implicitly keeping whatever unrelated string was there before.
Change-Id: Ifaf1b41e951e97f209ecb617b32ec4f7522b1d08
Reviewed-on: https://gerrit.libreoffice.org/17299
Reviewed-by: Eike Rathke <erack@redhat.com>
Reviewed-by: Michael Stahl <mstahl@redhat.com>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | svx/source/fmcomp/gridcell.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/svx/source/fmcomp/gridcell.cxx b/svx/source/fmcomp/gridcell.cxx index 52b828926c16..1e0cd51cdaca 100644 --- a/svx/source/fmcomp/gridcell.cxx +++ b/svx/source/fmcomp/gridcell.cxx @@ -1576,7 +1576,7 @@ void DbFormattedField::updateFromModel( Reference< XPropertySet > _rxModel ) OUString sText; Any aValue = _rxModel->getPropertyValue( FM_PROP_EFFECTIVE_VALUE ); - if ( aValue >>= sText ) + if ( !aValue.hasValue() || (aValue >>= sText) ) { // our effective value is transferred as string pFormattedWindow->SetTextFormatted( sText ); pFormattedWindow->SetSelection( Selection( SELECTION_MAX, SELECTION_MIN ) ); |