diff options
author | Ilhan Yesil <ilhanyesil@gmx.de> | 2018-04-11 15:44:11 +0200 |
---|---|---|
committer | Thorsten Behrens <Thorsten.Behrens@CIB.de> | 2018-06-01 09:52:33 +0200 |
commit | 2ded7acd61cf01a7c50d770b17605252738ed684 (patch) | |
tree | 325c13d422abe1fb84f6f718ca423643639b1725 /sc/source/ui | |
parent | 23b08449736ba825a9c582ba18b7a5fdba178e47 (diff) |
tdf#87995 Missing setting for save thumbnail in settings.xml.
If the user unchecks "Save preview picture with this document" in the
dialog field and saves the document, the appropriate flag is now
written to settings.xml by introducing the setting named
"SaveThumbnail".
Change-Id: I4916b4149a9494dd1891c0e05cb9a985ba0a9121
Reviewed-on: https://gerrit.libreoffice.org/52768
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de>
Diffstat (limited to 'sc/source/ui')
-rw-r--r-- | sc/source/ui/unoobj/confuno.cxx | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/sc/source/ui/unoobj/confuno.cxx b/sc/source/ui/unoobj/confuno.cxx index d892bba47647..042c548eae74 100644 --- a/sc/source/ui/unoobj/confuno.cxx +++ b/sc/source/ui/unoobj/confuno.cxx @@ -71,7 +71,8 @@ static const SfxItemPropertyMapEntry* lcl_GetConfigPropertyMap() {OUString(SC_UNO_PRINTERNAME), 0, cppu::UnoType<OUString>::get(), 0, 0}, {OUString(SC_UNO_PRINTERSETUP), 0, cppu::UnoType<uno::Sequence<sal_Int8>>::get(), 0, 0}, {OUString(SC_UNO_PRINTERPAPER), 0, cppu::UnoType<bool>::get(), 0, 0}, - {OUString(SC_UNO_APPLYDOCINF), 0, cppu::UnoType<bool>::get(), 0, 0}, + {OUString(SC_UNO_APPLYDOCINF), 0, cppu::UnoType<bool>::get(), 0, 0 }, + {OUString(SC_UNO_SAVE_THUMBNAIL), 0, cppu::UnoType<bool>::get(), 0, 0 }, {OUString(SC_UNO_FORBIDDEN), 0, cppu::UnoType<i18n::XForbiddenCharacters>::get(), beans::PropertyAttribute::READONLY, 0}, {OUString(SC_UNO_CHARCOMP), 0, cppu::UnoType<sal_Int16>::get(), 0, 0}, {OUString(SC_UNO_ASIANKERN), 0, cppu::UnoType<bool>::get(), 0, 0}, @@ -272,6 +273,12 @@ void SAL_CALL ScDocumentConfiguration::setPropertyValue( if ( aValue >>= bTmp ) pDocShell->SetUseUserData( bTmp ); } + else if ( aPropertyName == SC_UNO_SAVE_THUMBNAIL) + { + bool bTmp = true; + if (aValue >>= bTmp) + pDocShell->SetUseThumbnailSave( bTmp ); + } else if ( aPropertyName == SC_UNO_FORBIDDEN ) { // read-only - should not be set @@ -492,6 +499,8 @@ uno::Any SAL_CALL ScDocumentConfiguration::getPropertyValue( const OUString& aPr } else if ( aPropertyName == SC_UNO_APPLYDOCINF ) aRet <<= pDocShell->IsUseUserData(); + else if ( aPropertyName == SC_UNO_SAVE_THUMBNAIL ) + aRet <<= pDocShell->IsUseThumbnailSave(); else if ( aPropertyName == SC_UNO_FORBIDDEN ) { aRet <<= uno::Reference<i18n::XForbiddenCharacters>(new ScForbiddenCharsObj( pDocShell )); |