From 9fa4eff9be5e440099517a522a83e20debaf2955 Mon Sep 17 00:00:00 2001 From: Armin Le Grand Date: Thu, 15 Sep 2016 12:27:28 +0200 Subject: profilesafe: Enhancements to BackupFileHelper Added helper class to allow easy creation/deployment of backups of a file. It works like a 'stack' of backups, supports easy add/remove/delete of last entry (LIFO). Added some work top allow opening dialogs in DeInit under linux. Change-Id: Idacec97ec2f097af9bd22a8a67b410c7677d17f1 --- comphelper/source/misc/backupfilehelper.cxx | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'comphelper') diff --git a/comphelper/source/misc/backupfilehelper.cxx b/comphelper/source/misc/backupfilehelper.cxx index 778f0a0e7d27..7a353b8e90bb 100644 --- a/comphelper/source/misc/backupfilehelper.cxx +++ b/comphelper/source/misc/backupfilehelper.cxx @@ -15,6 +15,7 @@ namespace comphelper { sal_uInt16 BackupFileHelper::mnMaxAllowedBackups = 10; + bool BackupFileHelper::mbExitWasCalled = false; BackupFileHelper::BackupFileHelper( const OUString& rBaseURL, @@ -28,6 +29,16 @@ namespace comphelper { } + void BackupFileHelper::setExitWasCalled() + { + mbExitWasCalled = true; + } + + bool BackupFileHelper::getExitWasCalled() + { + return mbExitWasCalled; + } + bool BackupFileHelper::tryPush() { if (isDifferentOrNew()) -- cgit