summaryrefslogtreecommitdiff
path: root/unotools
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2021-07-24 09:30:49 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2021-07-25 12:56:18 +0200
commit293c1a629a69822b4a9996d0522513bc2a0d78e1 (patch)
tree595f7c02b6f1f7065df32ddb98a3d9a054dab0f4 /unotools
parentc05adac9229aad0683d2e75a8f8dcd5421c66b02 (diff)
use officecfg to retrieve LoadDocumentPrinter
Change-Id: Ie9c164fb9c95989035ef769d0dd539521400e38e Reviewed-on: https://gerrit.libreoffice.org/c/core/+/119463 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'unotools')
-rw-r--r--unotools/source/config/saveopt.cxx47
1 files changed, 2 insertions, 45 deletions
diff --git a/unotools/source/config/saveopt.cxx b/unotools/source/config/saveopt.cxx
index 0900817e484e..46fac1c81094 100644
--- a/unotools/source/config/saveopt.cxx
+++ b/unotools/source/config/saveopt.cxx
@@ -61,14 +61,12 @@ class SvtSaveOptions_Impl : public utl::ConfigItem
sal_Int32 nAutoSaveTime;
bool bUseUserData,
bBackup,
- bAutoSave,
- bLoadDocPrinter;
+ bAutoSave;
SvtSaveOptions::ODFDefaultVersion eODFDefaultVersion;
bool bROUseUserData,
bROBackup,
- bROLoadDocPrinter,
bROODFDefaultVersion;
virtual void ImplCommit() override;
@@ -80,14 +78,12 @@ public:
bool IsUseUserData() const { return bUseUserData; }
bool IsBackup() const { return bBackup; }
- bool IsLoadDocPrinter() const { return bLoadDocPrinter; }
SvtSaveOptions::ODFDefaultVersion
GetODFDefaultVersion() const { return eODFDefaultVersion; }
void SetUseUserData( bool b );
void SetBackup( bool b );
- void SetLoadDocPrinter( bool bNew );
void SetODFDefaultVersion( SvtSaveOptions::ODFDefaultVersion eNew );
bool IsReadOnly( SvtSaveOptions::EOption eOption ) const;
@@ -113,15 +109,6 @@ void SvtSaveOptions_Impl::SetBackup( bool b )
}
}
-void SvtSaveOptions_Impl::SetLoadDocPrinter( bool bNew )
-{
- if ( !bROLoadDocPrinter && bLoadDocPrinter != bNew )
- {
- bLoadDocPrinter = bNew;
- SetModified();
- }
-}
-
void SvtSaveOptions_Impl::SetODFDefaultVersion( SvtSaveOptions::ODFDefaultVersion eNew )
{
if ( !bROODFDefaultVersion && eODFDefaultVersion != eNew )
@@ -142,9 +129,6 @@ bool SvtSaveOptions_Impl::IsReadOnly( SvtSaveOptions::EOption eOption ) const
case SvtSaveOptions::EOption::Backup :
bReadOnly = bROBackup;
break;
- case SvtSaveOptions::EOption::LoadDocPrinter :
- bReadOnly = bROLoadDocPrinter;
- break;
case SvtSaveOptions::EOption::OdfDefaultVersion :
bReadOnly = bROODFDefaultVersion;
break;
@@ -155,8 +139,7 @@ bool SvtSaveOptions_Impl::IsReadOnly( SvtSaveOptions::EOption eOption ) const
#define FORMAT 0
#define USEUSERDATA 1
#define CREATEBACKUP 2
-#define LOADDOCPRINTER 3
-#define ODFDEFAULTVERSION 4
+#define ODFDEFAULTVERSION 3
static Sequence< OUString > GetPropertyNames()
{
@@ -165,7 +148,6 @@ static Sequence< OUString > GetPropertyNames()
"Graphic/Format",
"Document/UseUserData",
"Document/CreateBackup",
- "Document/LoadPrinter",
"ODF/DefaultVersion"
};
@@ -183,11 +165,9 @@ SvtSaveOptions_Impl::SvtSaveOptions_Impl()
, nAutoSaveTime( 0 )
, bUseUserData( false )
, bBackup( false )
- , bLoadDocPrinter( true )
, eODFDefaultVersion( SvtSaveOptions::ODFVER_LATEST )
, bROUseUserData( CFG_READONLY_DEFAULT )
, bROBackup( CFG_READONLY_DEFAULT )
- , bROLoadDocPrinter( CFG_READONLY_DEFAULT )
, bROODFDefaultVersion( CFG_READONLY_DEFAULT )
{
Sequence< OUString > aNames = GetPropertyNames();
@@ -243,11 +223,6 @@ SvtSaveOptions_Impl::SvtSaveOptions_Impl()
bROBackup = pROStates[nProp];
break;
- case LOADDOCPRINTER:
- bLoadDocPrinter = bTemp;
- bROLoadDocPrinter = pROStates[nProp];
- break;
-
default :
SAL_WARN( "unotools.config", "invalid index to load a path" );
}
@@ -309,14 +284,6 @@ void SvtSaveOptions_Impl::ImplCommit()
++nRealCount;
}
break;
- case LOADDOCPRINTER:
- if (!bROLoadDocPrinter)
- {
- pValues[nRealCount] <<= bLoadDocPrinter;
- pNames[nRealCount] = pOrgNames[i];
- ++nRealCount;
- }
- break;
case ODFDEFAULTVERSION:
if (!bROODFDefaultVersion)
{
@@ -457,16 +424,6 @@ bool SvtSaveOptions::IsLoadUserSettings() const
return pImp->pLoadOpt->IsLoadUserSettings();
}
-void SvtSaveOptions::SetLoadDocumentPrinter( bool _bEnable )
-{
- pImp->pSaveOpt->SetLoadDocPrinter( _bEnable );
-}
-
-bool SvtSaveOptions::IsLoadDocumentPrinter() const
-{
- return pImp->pSaveOpt->IsLoadDocPrinter();
-}
-
void SvtSaveOptions::SetODFDefaultVersion( SvtSaveOptions::ODFDefaultVersion eVersion )
{
pImp->pSaveOpt->SetODFDefaultVersion( eVersion );