[Libreoffice-commits] core.git: Branch 'feature/cib_contract57' - 55 commits - basctl/uiconfig chart2/uiconfig comphelper/Library_comphelper.mk comphelper/source configmgr/source dbaccess/uiconfig desktop/source extensions/uiconfig framework/inc framework/source framework/uiconfig include/comphelper include/framework include/sal include/sfx2 include/svtools include/svx include/unotools include/vcl instsetoo_native/CustomTarget_setup.mk reportdesign/uiconfig scp2/source sc/uiconfig sd/uiconfig sfx2/Library_sfx.mk sfx2/sdi sfx2/source sfx2/uiconfig sfx2/UIConfig_sfx.mk starmath/uiconfig svx/AllLangResTarget_svx.mk svx/Library_svx.mk svx/source svx/uiconfig svx/UIConfig_svx.mk svx/util sw/uiconfig unotools/Library_utl.mk unotools/source vcl/source
Katarina Behrens
Katarina.Behrens at cib.de
Tue Jan 17 17:42:37 UTC 2017
basctl/uiconfig/basicide/menubar/menubar.xml | 2
chart2/uiconfig/menubar/menubar.xml | 2
comphelper/Library_comphelper.mk | 2
comphelper/source/misc/backupfilehelper.cxx | 2755 ++++++++++++++++++
configmgr/source/components.cxx | 91
configmgr/source/components.hxx | 7
configmgr/source/modifications.hxx | 2
configmgr/source/writemodfile.cxx | 58
dbaccess/uiconfig/dbapp/menubar/menubar.xml | 2
dbaccess/uiconfig/dbquery/menubar/menubar.xml | 2
dbaccess/uiconfig/dbrelation/menubar/menubar.xml | 2
dbaccess/uiconfig/dbtable/menubar/menubar.xml | 2
dbaccess/uiconfig/dbtdata/menubar/menubar.xml | 2
desktop/source/app/app.cxx | 84
desktop/source/app/app.cxx.orig | 2735 +++++++++++++++++
desktop/source/app/appinit.cxx | 1
desktop/source/app/cmdlineargs.cxx | 5
desktop/source/app/cmdlineargs.hxx | 2
desktop/source/app/cmdlinehelp.cxx | 2
extensions/uiconfig/sbibliography/menubar/menubar.xml | 2
framework/inc/classes/resource.hrc | 1
framework/source/classes/resource.src | 5
framework/source/fwe/helper/titlehelper.cxx | 10
framework/uiconfig/startmodule/menubar/menubar.xml | 2
include/comphelper/backupfilehelper.hxx | 223 +
include/comphelper/package/ZipPackageHelper.hxx | 57
include/framework/titlehelper.hxx | 1
include/sal/log-areas.dox | 1
include/sfx2/safemode.hxx | 74
include/sfx2/sfxsids.hrc | 1
include/svtools/restartdialog.hxx | 3
include/svx/dialogs.hrc | 5
include/unotools/ZipPackageHelper.hxx | 65
include/vcl/svapp.hxx | 6
instsetoo_native/CustomTarget_setup.mk | 15
reportdesign/uiconfig/dbreport/menubar/menubar.xml | 2
sc/uiconfig/scalc/menubar/menubar.xml | 2
scp2/source/ooo/folderitem_ooo.scp | 23
sd/uiconfig/sdraw/menubar/menubar.xml | 2
sd/uiconfig/simpress/menubar/menubar.xml | 2
sfx2/Library_sfx.mk | 1
sfx2/UIConfig_sfx.mk | 1
sfx2/sdi/appslots.sdi | 5
sfx2/sdi/sfx.sdi | 17
sfx2/source/appl/appserv.cxx | 40
sfx2/source/safemode/safemode.cxx | 84
sfx2/uiconfig/ui/safemodequerydialog.ui | 83
starmath/uiconfig/smath/menubar/menubar.xml | 2
svx/AllLangResTarget_svx.mk | 1
svx/Library_svx.mk | 2
svx/UIConfig_svx.mk | 2
svx/source/dialog/SafeMode.src | 17
svx/source/dialog/SafeModeDialog.cxx | 445 ++
svx/source/dialog/SafeModeDialog.hxx | 80
svx/source/dialog/SafeModeUI.cxx | 99
svx/source/dialog/crashreportdlg.cxx | 22
svx/source/dialog/crashreportdlg.hxx | 3
svx/uiconfig/ui/crashreportdlg.ui | 15
svx/uiconfig/ui/profileexporteddialog.ui | 84
svx/uiconfig/ui/safemodedialog.ui | 485 +++
svx/util/svx.component | 4
sw/uiconfig/sglobal/menubar/menubar.xml | 2
sw/uiconfig/sweb/menubar/menubar.xml | 2
sw/uiconfig/swform/menubar/menubar.xml | 2
sw/uiconfig/swreport/menubar/menubar.xml | 2
sw/uiconfig/swriter/menubar/menubar.xml | 2
sw/uiconfig/swxform/menubar/menubar.xml | 2
unotools/Library_utl.mk | 1
unotools/source/misc/ZipPackageHelper.cxx | 199 +
vcl/source/app/svapp.cxx | 13
vcl/source/opengl/OpenGLHelper.cxx | 4
71 files changed, 7943 insertions(+), 38 deletions(-)
New commits:
commit 926c44effb1a712fad540fd9b770027b05a9cd4f
Author: Katarina Behrens <Katarina.Behrens at cib.de>
Date: Fri Jan 13 23:17:52 2017 +0100
SafeModeDialog: restart in normal mode instead of quitting
Change-Id: I546629656ada6c7a8a15b4dc77a042e1f1106924
Reviewed-on: https://gerrit.libreoffice.org/33059
Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
Tested-by: Katarina Behrens <Katarina.Behrens at cib.de>
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index 2371238..de34958 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -37,8 +37,8 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
: Dialog(pParent, "SafeModeDialog", "svx/ui/safemodedialog.ui"),
mpBtnContinue(),
- mpBtnQuit(),
mpBtnRestart(),
+ mpBtnApply(),
mpBoxRestore(),
mpBoxConfigure(),
@@ -63,8 +63,8 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
maBackupFileHelper()
{
get(mpBtnContinue, "btn_continue");
- get(mpBtnQuit, "btn_quit");
get(mpBtnRestart, "btn_restart");
+ get(mpBtnApply, "btn_apply");
get(mpBoxRestore, "group_restore");
get(mpBoxConfigure, "group_configure");
@@ -96,8 +96,8 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpRadioReset->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
mpBtnContinue->SetClickHdl(LINK(this, SafeModeDialog, DialogBtnHdl));
- mpBtnQuit->SetClickHdl(LINK(this, SafeModeDialog, DialogBtnHdl));
mpBtnRestart->SetClickHdl(LINK(this, SafeModeDialog, DialogBtnHdl));
+ mpBtnApply->SetClickHdl(LINK(this, SafeModeDialog, DialogBtnHdl));
mpCBCheckProfilesafeConfig->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBCheckProfilesafeExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
@@ -113,7 +113,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpBtnCreateZip->SetClickHdl(LINK(this, SafeModeDialog, CreateZipBtnHdl));
// Disable restart btn until some checkbox is active
- mpBtnRestart->Disable();
+ mpBtnApply->Disable();
// Check the first radio button and call its handler,
// it'll disable the relevant parts
@@ -146,8 +146,8 @@ void SafeModeDialog::dispose()
mpBoxReset.clear();
mpBtnContinue.clear();
- mpBtnQuit.clear();
mpBtnRestart.clear();
+ mpBtnApply.clear();
mpCBCheckProfilesafeConfig.clear();
mpCBCheckProfilesafeExtensions.clear();
@@ -345,12 +345,15 @@ IMPL_LINK(SafeModeDialog, DialogBtnHdl, Button*, pBtn)
{
Close();
}
- else if (pBtn == mpBtnQuit.get())
+ else if (pBtn == mpBtnRestart.get())
{
+ sfx2::SafeMode::putRestartFlag();
Close();
- Application::Quit();
+ uno::Reference< uno::XComponentContext > xContext = comphelper::getProcessComponentContext();
+ css::task::OfficeRestartManager::get(xContext)->requestRestart(
+ css::uno::Reference< css::task::XInteractionHandler >());
}
- else if (pBtn == mpBtnRestart.get())
+ else if (pBtn == mpBtnApply.get())
{
sfx2::SafeMode::putRestartFlag();
Close();
@@ -427,7 +430,7 @@ IMPL_LINK(SafeModeDialog, CheckBoxHdl, CheckBox*, /*pCheckBox*/ )
mpCBResetCustomizations->IsChecked() ||
mpCBResetWholeUserProfile->IsChecked());
- mpBtnRestart->Enable(bEnable);
+ mpBtnApply->Enable(bEnable);
return 0;
}
diff --git a/svx/source/dialog/SafeModeDialog.hxx b/svx/source/dialog/SafeModeDialog.hxx
index 978fd82..8979d73 100644
--- a/svx/source/dialog/SafeModeDialog.hxx
+++ b/svx/source/dialog/SafeModeDialog.hxx
@@ -34,8 +34,8 @@ public:
private:
VclPtr<Button> mpBtnContinue;
- VclPtr<Button> mpBtnQuit;
VclPtr<Button> mpBtnRestart;
+ VclPtr<Button> mpBtnApply;
VclPtr<VclBox> mpBoxRestore;
VclPtr<VclBox> mpBoxConfigure;
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index c2ce6fe..ef41c28 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -48,8 +48,8 @@
</packing>
</child>
<child>
- <object class="GtkButton" id="btn_quit">
- <property name="label" translatable="yes">_Quit</property>
+ <object class="GtkButton" id="btn_restart">
+ <property name="label" translatable="yes">_Restart in Normal Mode</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
@@ -62,7 +62,7 @@
</packing>
</child>
<child>
- <object class="GtkButton" id="btn_restart">
+ <object class="GtkButton" id="btn_apply">
<property name="label" translatable="yes">_Apply Changes and Restart</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
commit a4ab7e742f8b1d7b20b2c8a8a659285dee648ade
Author: Katarina Behrens <Katarina.Behrens at cib.de>
Date: Fri Jan 13 15:33:48 2017 +0100
SafeMode: Deactivate 'Restart in safe mode' when already in safe mode
Change-Id: I75f7024528190cf3732fb80063132ef0c6de3118
Reviewed-on: https://gerrit.libreoffice.org/33049
Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
Tested-by: Katarina Behrens <Katarina.Behrens at cib.de>
diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx
index 906bc1d..b003969 100644
--- a/sfx2/source/appl/appserv.cxx
+++ b/sfx2/source/appl/appserv.cxx
@@ -858,6 +858,9 @@ void SfxApplication::MiscState_Impl(SfxItemSet &rSet)
case SID_SAFE_MODE:
{
+ // no restart in safe mode when already in safe mode
+ if ( Application::IsSafeModeEnabled() )
+ rSet.DisableItem( SID_SAFE_MODE );
break;
}
commit 6775d1414b57a87b466126a684233617d567807c
Author: Katarina Behrens <Katarina.Behrens at cib.de>
Date: Wed Jan 11 14:47:47 2017 +0100
SafeModeDialog: set correct initial checkbox state
Change-Id: I3aa45ae4b02afd2ea8e1a5a427eb6f0f17219430
Reviewed-on: https://gerrit.libreoffice.org/32967
Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
Tested-by: Katarina Behrens <Katarina.Behrens at cib.de>
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index e9ff29c..2371238 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -115,11 +115,10 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
// Disable restart btn until some checkbox is active
mpBtnRestart->Disable();
- // Check the first radio button and disable the other parts
+ // Check the first radio button and call its handler,
+ // it'll disable the relevant parts
mpRadioRestore->Check();
- mpBoxConfigure->Disable();
- mpBoxDeinstall->Disable();
- mpBoxReset->Disable();
+ RadioBtnHdl( mpRadioRestore );
// Set URL for help button (module=safemode)
OUString sURL("http://hub.libreoffice.org/send-feedback/?LOversion=" + utl::ConfigManager::getAboutBoxProductVersion() +
commit b01fe88564816b6d458d633fe02d34ee23d3231a
Author: Stephan Bergmann <sbergman at redhat.com>
Date: Thu Aug 27 13:06:15 2015 +0200
Simplify hasModifications check
Change-Id: Idcbd9a20ab13d0717f8728673e2c55e87aa92be4
diff --git a/configmgr/source/components.cxx b/configmgr/source/components.cxx
index 5b21e30..dc7d979 100644
--- a/configmgr/source/components.cxx
+++ b/configmgr/source/components.cxx
@@ -273,14 +273,8 @@ void Components::addModification(Path const & path) {
data_.modifications.add(path);
}
-bool Components::hasModifications() const
-{
- return data_.modifications.getRoot().children.begin() !=
- data_.modifications.getRoot().children.end();
-}
-
void Components::writeModifications() {
- if (hasModifications()) {
+ if (!data_.modifications.empty()) {
switch (modificationTarget_) {
case ModificationTarget::None:
break;
diff --git a/configmgr/source/components.hxx b/configmgr/source/components.hxx
index 914995e..d372771 100644
--- a/configmgr/source/components.hxx
+++ b/configmgr/source/components.hxx
@@ -79,8 +79,6 @@ public:
void writeModifications();
- bool hasModifications() const;
-
void flushModifications();
// must be called with configmgr::lock unaquired; must be called before
// shutdown if writeModifications has ever been called (probably
diff --git a/configmgr/source/modifications.hxx b/configmgr/source/modifications.hxx
index 71e06ea..04ad5c3 100644
--- a/configmgr/source/modifications.hxx
+++ b/configmgr/source/modifications.hxx
@@ -45,6 +45,8 @@ public:
void remove(Path const & path);
+ bool empty() const { return root_.children.empty(); }
+
Node const & getRoot() const { return root_;}
private:
commit dc37074c4533f9651f09cce63074b682e28f6939
Author: Katarina Behrens <Katarina.Behrens at cib.de>
Date: Tue Dec 13 16:12:06 2016 +0100
SafeMode: s/LibreOffice/%PRODUCTNAME/, small UI changes
nouns are written Upper Case only in German
also Cancel button looks odd as secondary
Change-Id: Id1b051cbb86ab69ea88c7b1da2cda3eb19f063de
Reviewed-on: https://gerrit.libreoffice.org/31971
Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
Tested-by: Katarina Behrens <Katarina.Behrens at cib.de>
diff --git a/sfx2/uiconfig/ui/safemodequerydialog.ui b/sfx2/uiconfig/ui/safemodequerydialog.ui
index 8a24691..72bab52 100644
--- a/sfx2/uiconfig/ui/safemodequerydialog.ui
+++ b/sfx2/uiconfig/ui/safemodequerydialog.ui
@@ -32,7 +32,6 @@
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">0</property>
- <property name="secondary">True</property>
</packing>
</child>
<child>
@@ -61,7 +60,7 @@
<object class="GtkLabel" id="label">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">Are you sure you want to restart %PRODUCTNAME and enter the Safe Mode?</property>
+ <property name="label" translatable="yes">Are you sure you want to restart %PRODUCTNAME and enter safe mode?</property>
<property name="wrap">True</property>
<property name="max_width_chars">80</property>
<property name="lines">2</property>
diff --git a/svx/uiconfig/ui/crashreportdlg.ui b/svx/uiconfig/ui/crashreportdlg.ui
index 4b8b229..d993eb0 100644
--- a/svx/uiconfig/ui/crashreportdlg.ui
+++ b/svx/uiconfig/ui/crashreportdlg.ui
@@ -113,7 +113,7 @@ Thank you for your help in improving %PRODUCTNAME.</property>
</child>
<child>
<object class="GtkCheckButton" id="check_safemode">
- <property name="label" translatable="yes">Restart LibreOffice to enter Safe Mode</property>
+ <property name="label" translatable="yes">Restart %PRODUCTNAME to enter safe mode</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
commit fc33d468d5ea9c86ca105c864acdd82f399a40c3
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Mon Dec 12 17:29:28 2016 +0100
SafeMode: Restart goes into safe mode again
Looks like the XRestartManager keeps all command line arguments when
restarting, so it also keeps --safe-mode.
Solution is to add a flag file when restarting from safe mode,
to prevent going into safe mode again.
Change-Id: I9820d3ccbddf98b0bf6132f254c989f52ea5e808
Reviewed-on: https://gerrit.libreoffice.org/31913
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index c72b485..1ae2a8a 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -564,7 +564,10 @@ void Desktop::Init()
// Check whether safe mode is enabled
CommandLineArgs& rCmdLine = GetCommandLineArgs();
- if (rCmdLine.IsSafeMode() || sfx2::SafeMode::hasFlag())
+ // Check if we are restarting from safe mode - in that case we don't want to enter it again
+ if (sfx2::SafeMode::hasRestartFlag())
+ sfx2::SafeMode::removeRestartFlag();
+ else if (rCmdLine.IsSafeMode() || sfx2::SafeMode::hasFlag())
Application::EnableSafeMode();
// When we are in SafeMode we need to do changes before the configuration
diff --git a/include/sfx2/safemode.hxx b/include/sfx2/safemode.hxx
index 03f8590..47034f6 100644
--- a/include/sfx2/safemode.hxx
+++ b/include/sfx2/safemode.hxx
@@ -40,9 +40,31 @@ public:
*/
static bool removeFlag();
+ /**
+ * Write a flag to the user profile indicating that we are currently restarting from safe mode -
+ * that means we don't want to enter safe mode again.
+ *
+ * @return Whether the file could be written successfully
+ */
+ static bool putRestartFlag();
+
+ /**
+ * Check the existence of the restart flag file.
+ *
+ * @return Whether the restart flag file exists
+ */
+ static bool hasRestartFlag();
+
+ /**
+ * Remove the restart flag file.
+ *
+ * @return Whether the flag file could be removed successfully
+ */
+ static bool removeRestartFlag();
+
private:
/** Returns the path of the safe mode flag file.*/
- static OUString getFileName();
+ static OUString getFilePath(const OUString& sFilename);
};
}
diff --git a/sfx2/source/safemode/safemode.cxx b/sfx2/source/safemode/safemode.cxx
index a5669d1..609ebbd 100644
--- a/sfx2/source/safemode/safemode.cxx
+++ b/sfx2/source/safemode/safemode.cxx
@@ -20,7 +20,7 @@ namespace sfx2 {
bool SafeMode::putFlag()
{
- File safeModeFile(getFileName());
+ File safeModeFile(getFilePath("safemode"));
if (safeModeFile.open(osl_File_OpenFlag_Create) == FileBase::E_None)
{
safeModeFile.close();
@@ -30,7 +30,7 @@ bool SafeMode::putFlag()
}
bool SafeMode::hasFlag()
{
- File safeModeFile(getFileName());
+ File safeModeFile(getFilePath("safemode"));
if (safeModeFile.open(osl_File_OpenFlag_Read) == FileBase::E_None)
{
safeModeFile.close();
@@ -40,16 +40,42 @@ bool SafeMode::hasFlag()
}
bool SafeMode::removeFlag()
{
- return File::remove(getFileName()) == FileBase::E_None;
+ return File::remove(getFilePath("safemode")) == FileBase::E_None;
}
-OUString SafeMode::getFileName()
+bool SafeMode::putRestartFlag()
+{
+ File restartFile(getFilePath("safemode_restart"));
+ if (restartFile.open(osl_File_OpenFlag_Create) == FileBase::E_None)
+ {
+ restartFile.close();
+ return true;
+ }
+ return false;
+}
+bool SafeMode::hasRestartFlag()
+{
+ File restartFile(getFilePath("safemode_restart"));
+ if (restartFile.open(osl_File_OpenFlag_Read) == FileBase::E_None)
+ {
+ restartFile.close();
+ return true;
+ }
+ return false;
+}
+bool SafeMode::removeRestartFlag()
+{
+ return File::remove(getFilePath("safemode_restart")) == FileBase::E_None;
+}
+
+OUString SafeMode::getFilePath(const OUString& sFilename)
{
OUString url("${$BRAND_BASE_DIR/" LIBO_ETC_FOLDER "/" SAL_CONFIGFILE("bootstrap") ":UserInstallation}/safemode");
rtl::Bootstrap::expandMacros(url);
OUString aProfilePath;
FileBase::getSystemPathFromFileURL(url, aProfilePath);
+ FileBase::getAbsoluteFileURL(url, sFilename, aProfilePath);
return aProfilePath;
}
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index 59db86c..e9ff29c 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -353,6 +353,7 @@ IMPL_LINK(SafeModeDialog, DialogBtnHdl, Button*, pBtn)
}
else if (pBtn == mpBtnRestart.get())
{
+ sfx2::SafeMode::putRestartFlag();
Close();
applyChanges();
}
commit 451c7bd550e34403e5ae0d8abb0a1758ff6c5140
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Tue Dec 6 21:23:13 2016 +0100
SafeModeDialog: Rename widget to match label
Change-Id: I6bb02527fa77846343e55ff73497d1b46b5e1ba8
Reviewed-on: https://gerrit.libreoffice.org/31699
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index da94888..59db86c 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -47,7 +47,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpRadioRestore(),
mpRadioConfigure(),
- mpRadioDeinstall(),
+ mpRadioExtensions(),
mpRadioReset(),
mpCBCheckProfilesafeConfig(),
@@ -73,7 +73,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
get(mpRadioRestore, "radio_restore");
get(mpRadioConfigure, "radio_configure");
- get(mpRadioDeinstall, "radio_deinstall");
+ get(mpRadioExtensions, "radio_extensions");
get(mpRadioReset, "radio_reset");
get(mpCBCheckProfilesafeConfig, "check_profilesafe_config");
@@ -92,7 +92,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpRadioRestore->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
mpRadioConfigure->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
- mpRadioDeinstall->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
+ mpRadioExtensions->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
mpRadioReset->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
mpBtnContinue->SetClickHdl(LINK(this, SafeModeDialog, DialogBtnHdl));
@@ -138,7 +138,7 @@ void SafeModeDialog::dispose()
{
mpRadioRestore.clear();
mpRadioConfigure.clear();
- mpRadioDeinstall.clear();
+ mpRadioExtensions.clear();
mpRadioReset.clear();
mpBoxRestore.clear();
@@ -223,7 +223,8 @@ void SafeModeDialog::applyChanges()
}
}
- if (mpRadioDeinstall->IsChecked())
+ // Deinstall
+ if (mpRadioExtensions->IsChecked())
{
if (mpCBDeinstallUserExtensions->IsChecked())
{
@@ -289,7 +290,7 @@ IMPL_LINK(SafeModeDialog, RadioBtnHdl, Button*, pBtn)
mpBoxDeinstall->Disable();
}
- else if (pBtn == mpRadioDeinstall.get())
+ else if (pBtn == mpRadioExtensions.get())
{
// Enable the currently selected box
mpBoxDeinstall->Enable();
diff --git a/svx/source/dialog/SafeModeDialog.hxx b/svx/source/dialog/SafeModeDialog.hxx
index 615236b..978fd82 100644
--- a/svx/source/dialog/SafeModeDialog.hxx
+++ b/svx/source/dialog/SafeModeDialog.hxx
@@ -44,7 +44,7 @@ private:
VclPtr<RadioButton> mpRadioRestore;
VclPtr<RadioButton> mpRadioConfigure;
- VclPtr<RadioButton> mpRadioDeinstall;
+ VclPtr<RadioButton> mpRadioExtensions;
VclPtr<RadioButton> mpRadioReset;
VclPtr<CheckBox> mpCBCheckProfilesafeConfig;
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index 10a5c8f..c2ce6fe 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -230,7 +230,7 @@ The proposed changes get more radical from top down so it is recommended to try
</packing>
</child>
<child>
- <object class="GtkRadioButton" id="radio_deinstall">
+ <object class="GtkRadioButton" id="radio_extensions">
<property name="label" translatable="yes">Extensions</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
commit 0daaf2f4048658533117e3607c783183c582e407
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Tue Dec 6 18:31:07 2016 +0100
SafeModeDialog: Add option to reset bundled extension registration
Change-Id: Ic83ada7cc76142852643cefa60b4fc9286e0756a
Reviewed-on: https://gerrit.libreoffice.org/31694
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/comphelper/source/misc/backupfilehelper.cxx b/comphelper/source/misc/backupfilehelper.cxx
index 1796fff..292614e 100644
--- a/comphelper/source/misc/backupfilehelper.cxx
+++ b/comphelper/source/misc/backupfilehelper.cxx
@@ -568,10 +568,12 @@ namespace
{
private:
ExtensionInfoEntryVector maEntries;
+ OUString maRegPath;
public:
ExtensionInfo()
- : maEntries()
+ : maEntries(),
+ maRegPath("/registry/com.sun.star.comp.deployment.bundle.PackageRegistryBackend/backenddb.xml")
{
}
@@ -691,21 +693,27 @@ namespace
}
public:
- void createUsingExtensionRegistryEntriesFromXML(
- const OUString& rUserConfigWorkURL,
- bool bUser)
- {
- // This is looked up for 'user' in the user|shared|bundled deployed Extensions,
- // only the user ones seem to be able to be de/activated. The ones for user are in
- // uno_packages/cache while the others are in /extensions/shared.
- // This also means that all user-deployed Extensions can probably be uninstalled
- // in safe mode by deleting the uno_packages directory and the shared|bundled
- // ones by deleting the extensions directory.
- const OUString aRegPath("/registry/com.sun.star.comp.deployment.bundle.PackageRegistryBackend/backenddb.xml");
- const OUString aExtensionsReg(rUserConfigWorkURL + "/extensions/shared" + aRegPath);
- const OUString aUnoPackageReg(rUserConfigWorkURL + "/uno_packages/cache" + aRegPath);
- const OUString aPath(bUser ? aUnoPackageReg : aExtensionsReg);
+ void createUserExtensionRegistryEntriesFromXML(const OUString& rUserConfigWorkURL)
+ {
+ const OUString aPath(rUserConfigWorkURL + "/uno_packages/cache" + maRegPath);
+ createExtensionRegistryEntriesFromXML(aPath);
+ }
+
+ void createSharedExtensionRegistryEntriesFromXML(const OUString& rUserConfigWorkURL)
+ {
+ const OUString aPath(rUserConfigWorkURL + "/extensions/shared" + maRegPath);
+ createExtensionRegistryEntriesFromXML(aPath);
+ }
+ void createBundledExtensionRegistryEntriesFromXML(const OUString& rUserConfigWorkURL)
+ {
+ const OUString aPath(rUserConfigWorkURL + "/extensions/bundled" + maRegPath);
+ createExtensionRegistryEntriesFromXML(aPath);
+ }
+
+
+ void createExtensionRegistryEntriesFromXML(const OUString& aPath)
+ {
if (fileExists(aPath))
{
uno::Reference< uno::XComponentContext > xContext = ::comphelper::getProcessComponentContext();
@@ -1990,7 +1998,7 @@ namespace comphelper
// extensions are not loaded from XExtensionManager
class ExtensionInfo aExtensionInfo;
- aExtensionInfo.createUsingExtensionRegistryEntriesFromXML(maUserConfigWorkURL, true);
+ aExtensionInfo.createUserExtensionRegistryEntriesFromXML(maUserConfigWorkURL);
return aExtensionInfo.areThereEnabledExtensions();
}
@@ -2004,7 +2012,7 @@ namespace comphelper
const ExtensionInfoEntryVector aToBeEnabled;
ExtensionInfoEntryVector aToBeDisabled;
- aCurrentExtensionInfo.createUsingExtensionRegistryEntriesFromXML(maUserConfigWorkURL, true);
+ aCurrentExtensionInfo.createUserExtensionRegistryEntriesFromXML(maUserConfigWorkURL);
const ExtensionInfoEntryVector& rCurrentVector = aCurrentExtensionInfo.getExtensionInfoEntryVector();
@@ -2024,7 +2032,7 @@ namespace comphelper
// check if there are User Extensions installed.
class ExtensionInfo aExtensionInfo;
- aExtensionInfo.createUsingExtensionRegistryEntriesFromXML(maUserConfigWorkURL, true);
+ aExtensionInfo.createUserExtensionRegistryEntriesFromXML(maUserConfigWorkURL);
return !aExtensionInfo.getExtensionInfoEntryVector().empty();
}
@@ -2040,7 +2048,7 @@ namespace comphelper
// check if there are shared Extensions installed
class ExtensionInfo aExtensionInfo;
- aExtensionInfo.createUsingExtensionRegistryEntriesFromXML(maUserConfigWorkURL, false);
+ aExtensionInfo.createSharedExtensionRegistryEntriesFromXML(maUserConfigWorkURL);
return !aExtensionInfo.getExtensionInfoEntryVector().empty();
}
@@ -2051,6 +2059,22 @@ namespace comphelper
deleteDirRecursively(maUserConfigWorkURL + "/extensions/shared");
}
+ bool BackupFileHelper::isTryResetBundledExtensionsPossible()
+ {
+ // check if there are shared Extensions installed
+ class ExtensionInfo aExtensionInfo;
+
+ aExtensionInfo.createBundledExtensionRegistryEntriesFromXML(maUserConfigWorkURL);
+
+ return !aExtensionInfo.getExtensionInfoEntryVector().empty();
+ }
+
+ void BackupFileHelper::tryResetBundledExtensions()
+ {
+ // reset shared extension info
+ deleteDirRecursively(maUserConfigWorkURL + "/extensions/bundled");
+ }
+
const std::vector< OUString >& BackupFileHelper::getCustomizationDirNames()
{
static std::vector< OUString > aDirNames;
@@ -2552,7 +2576,7 @@ namespace comphelper
// get current extension info, but from XML config files
ExtensionInfo aCurrentExtensionInfo;
- aCurrentExtensionInfo.createUsingExtensionRegistryEntriesFromXML(maUserConfigWorkURL, true);
+ aCurrentExtensionInfo.createUserExtensionRegistryEntriesFromXML(maUserConfigWorkURL);
// now we have loaded last_working (aLoadedExtensionInfo) and
// current (aCurrentExtensionInfo) ExtensionInfo and may react on
diff --git a/include/comphelper/backupfilehelper.hxx b/include/comphelper/backupfilehelper.hxx
index 3ffbc07..19c4f9c 100644
--- a/include/comphelper/backupfilehelper.hxx
+++ b/include/comphelper/backupfilehelper.hxx
@@ -162,11 +162,16 @@ namespace comphelper
static bool isTryDeinstallUserExtensionsPossible();
static void tryDeinstallUserExtensions();
- /** Deinstall all Extensions (user|shared|bundled)
+ /** Reset shared Extensions
*/
static bool isTryResetSharedExtensionsPossible();
static void tryResetSharedExtensions();
+ /** Reset bundled Extensions
+ */
+ static bool isTryResetBundledExtensionsPossible();
+ static void tryResetBundledExtensions();
+
/// Disables OpenGL and OpenCL
static void tryDisableHWAcceleration();
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index 92fbb65..da94888 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -55,6 +55,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpCBDisableAllExtensions(),
mpCBDeinstallUserExtensions(),
mpCBResetSharedExtensions(),
+ mpCBResetBundledExtensions(),
mpCBDisableHWAcceleration(),
mpCBResetCustomizations(),
mpCBResetWholeUserProfile(),
@@ -80,6 +81,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
get(mpCBDisableAllExtensions, "check_disable_all_extensions");
get(mpCBDeinstallUserExtensions, "check_deinstall_user_extensions");
get(mpCBResetSharedExtensions, "check_reset_shared_extensions");
+ get(mpCBResetBundledExtensions, "check_reset_bundled_extensions");
get(mpCBDisableHWAcceleration, "check_disable_hw_acceleration");
get(mpCBResetCustomizations, "check_reset_customizations");
get(mpCBResetWholeUserProfile, "check_reset_whole_userprofile");
@@ -102,6 +104,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpCBDisableAllExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBDeinstallUserExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBResetSharedExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
+ mpCBResetBundledExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBDisableHWAcceleration->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBResetCustomizations->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBResetWholeUserProfile->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
@@ -152,6 +155,7 @@ void SafeModeDialog::dispose()
mpCBDisableAllExtensions.clear();
mpCBDeinstallUserExtensions.clear();
mpCBResetSharedExtensions.clear();
+ mpCBResetBundledExtensions.clear();
mpCBDisableHWAcceleration.clear();
mpCBResetCustomizations.clear();
mpCBResetWholeUserProfile.clear();
@@ -170,6 +174,7 @@ void SafeModeDialog::enableDisableWidgets()
mpCBDisableAllExtensions->Enable(comphelper::BackupFileHelper::isTryDisableAllExtensionsPossible());
mpCBDeinstallUserExtensions->Enable(comphelper::BackupFileHelper::isTryDeinstallUserExtensionsPossible());
mpCBResetSharedExtensions->Enable(comphelper::BackupFileHelper::isTryResetSharedExtensionsPossible());
+ mpCBResetBundledExtensions->Enable(comphelper::BackupFileHelper::isTryResetBundledExtensionsPossible());
mpCBResetCustomizations->Enable(comphelper::BackupFileHelper::isTryResetCustomizationsPossible());
// no disable of mpCBResetWholeUserProfile, always possible (as last choice)
@@ -231,6 +236,11 @@ void SafeModeDialog::applyChanges()
// Reset shared Extensions
comphelper::BackupFileHelper::tryResetSharedExtensions();
}
+ if (mpCBResetBundledExtensions->IsChecked())
+ {
+ // Reset bundled Extensions
+ comphelper::BackupFileHelper::tryResetBundledExtensions();
+ }
}
// Reset
@@ -411,6 +421,7 @@ IMPL_LINK(SafeModeDialog, CheckBoxHdl, CheckBox*, /*pCheckBox*/ )
mpCBDisableAllExtensions->IsChecked() ||
mpCBDeinstallUserExtensions->IsChecked() ||
mpCBResetSharedExtensions->IsChecked() ||
+ mpCBResetBundledExtensions->IsChecked() ||
mpCBDisableHWAcceleration->IsChecked() ||
mpCBResetCustomizations->IsChecked() ||
mpCBResetWholeUserProfile->IsChecked());
diff --git a/svx/source/dialog/SafeModeDialog.hxx b/svx/source/dialog/SafeModeDialog.hxx
index 91e4c66..615236b 100644
--- a/svx/source/dialog/SafeModeDialog.hxx
+++ b/svx/source/dialog/SafeModeDialog.hxx
@@ -52,6 +52,7 @@ private:
VclPtr<CheckBox> mpCBDisableAllExtensions;
VclPtr<CheckBox> mpCBDeinstallUserExtensions;
VclPtr<CheckBox> mpCBResetSharedExtensions;
+ VclPtr<CheckBox> mpCBResetBundledExtensions;
VclPtr<CheckBox> mpCBDisableHWAcceleration;
VclPtr<CheckBox> mpCBResetCustomizations;
VclPtr<CheckBox> mpCBResetWholeUserProfile;
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index feb5326..10a5c8f 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -264,7 +264,7 @@ The proposed changes get more radical from top down so it is recommended to try
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">1</property>
+ <property name="position">0</property>
</packing>
</child>
<child>
@@ -279,6 +279,21 @@ The proposed changes get more radical from top down so it is recommended to try
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkCheckButton" id="check_reset_bundled_extensions">
+ <property name="label" translatable="yes">Reset state of bundled extensions</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
<property name="position">2</property>
</packing>
</child>
commit 037c2c46fcaf22d9b0c98609fc67899e3f0c8eb4
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Tue Dec 6 17:23:27 2016 +0100
SafeModeDialog: Rename to match reality
This doesn't remove shared&bundled extensions, but resets the registration
database from shared extensions.
Change-Id: I9f198fc7b771fd3bd31547008fd8d006a6d1b5d5
Reviewed-on: https://gerrit.libreoffice.org/31693
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/comphelper/source/misc/backupfilehelper.cxx b/comphelper/source/misc/backupfilehelper.cxx
index 208fb4b..1796fff 100644
--- a/comphelper/source/misc/backupfilehelper.cxx
+++ b/comphelper/source/misc/backupfilehelper.cxx
@@ -2035,9 +2035,9 @@ namespace comphelper
deleteDirRecursively(maUserConfigWorkURL + "/uno_packages");
}
- bool BackupFileHelper::isTryDeinstallAllExtensionsPossible()
+ bool BackupFileHelper::isTryResetSharedExtensionsPossible()
{
- // check if there are other Extensions installed (shared|bundled).
+ // check if there are shared Extensions installed
class ExtensionInfo aExtensionInfo;
aExtensionInfo.createUsingExtensionRegistryEntriesFromXML(maUserConfigWorkURL, false);
@@ -2045,10 +2045,10 @@ namespace comphelper
return !aExtensionInfo.getExtensionInfoEntryVector().empty();
}
- void BackupFileHelper::tryDeinstallAllExtensions()
+ void BackupFileHelper::tryResetSharedExtensions()
{
- // delete other Extension installs (shared|bundled)
- deleteDirRecursively(maUserConfigWorkURL + "/extensions");
+ // reset shared extension info
+ deleteDirRecursively(maUserConfigWorkURL + "/extensions/shared");
}
const std::vector< OUString >& BackupFileHelper::getCustomizationDirNames()
diff --git a/include/comphelper/backupfilehelper.hxx b/include/comphelper/backupfilehelper.hxx
index e9b4183..3ffbc07 100644
--- a/include/comphelper/backupfilehelper.hxx
+++ b/include/comphelper/backupfilehelper.hxx
@@ -164,8 +164,8 @@ namespace comphelper
/** Deinstall all Extensions (user|shared|bundled)
*/
- static bool isTryDeinstallAllExtensionsPossible();
- static void tryDeinstallAllExtensions();
+ static bool isTryResetSharedExtensionsPossible();
+ static void tryResetSharedExtensions();
/// Disables OpenGL and OpenCL
static void tryDisableHWAcceleration();
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index 1eeb91c..92fbb65 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -54,7 +54,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpCBCheckProfilesafeExtensions(),
mpCBDisableAllExtensions(),
mpCBDeinstallUserExtensions(),
- mpCBDeinstallAllExtensions(),
+ mpCBResetSharedExtensions(),
mpCBDisableHWAcceleration(),
mpCBResetCustomizations(),
mpCBResetWholeUserProfile(),
@@ -79,7 +79,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
get(mpCBCheckProfilesafeExtensions, "check_profilesafe_extensions");
get(mpCBDisableAllExtensions, "check_disable_all_extensions");
get(mpCBDeinstallUserExtensions, "check_deinstall_user_extensions");
- get(mpCBDeinstallAllExtensions, "check_deinstall_all_extensions");
+ get(mpCBResetSharedExtensions, "check_reset_shared_extensions");
get(mpCBDisableHWAcceleration, "check_disable_hw_acceleration");
get(mpCBResetCustomizations, "check_reset_customizations");
get(mpCBResetWholeUserProfile, "check_reset_whole_userprofile");
@@ -101,7 +101,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpCBCheckProfilesafeExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBDisableAllExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBDeinstallUserExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
- mpCBDeinstallAllExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
+ mpCBResetSharedExtensions->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBDisableHWAcceleration->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBResetCustomizations->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
mpCBResetWholeUserProfile->SetToggleHdl(LINK(this, SafeModeDialog, CheckBoxHdl));
@@ -151,7 +151,7 @@ void SafeModeDialog::dispose()
mpCBCheckProfilesafeExtensions.clear();
mpCBDisableAllExtensions.clear();
mpCBDeinstallUserExtensions.clear();
- mpCBDeinstallAllExtensions.clear();
+ mpCBResetSharedExtensions.clear();
mpCBDisableHWAcceleration.clear();
mpCBResetCustomizations.clear();
mpCBResetWholeUserProfile.clear();
@@ -165,36 +165,14 @@ void SafeModeDialog::dispose()
void SafeModeDialog::enableDisableWidgets()
{
- if (!maBackupFileHelper.isPopPossible())
- {
- mpCBCheckProfilesafeConfig->Disable();
- }
-
- if (!maBackupFileHelper.isPopPossibleExtensionInfo())
- {
- mpCBCheckProfilesafeExtensions->Disable();
- }
-
- if (!comphelper::BackupFileHelper::isTryDisableAllExtensionsPossible())
- {
- mpCBDisableAllExtensions->Disable();
- }
-
- if (!comphelper::BackupFileHelper::isTryDeinstallUserExtensionsPossible())
- {
- mpCBDeinstallUserExtensions->Disable();
- }
-
- if (!comphelper::BackupFileHelper::isTryDeinstallAllExtensionsPossible())
- {
- mpCBDeinstallAllExtensions->Disable();
- }
-
- if (!comphelper::BackupFileHelper::isTryResetCustomizationsPossible())
- {
- mpCBResetCustomizations->Disable();
- }
- // no disabe of mpCBResetWholeUserProfile, always possible (as last choice)
+ mpCBCheckProfilesafeConfig->Enable(maBackupFileHelper.isPopPossible());
+ mpCBCheckProfilesafeExtensions->Enable(maBackupFileHelper.isPopPossibleExtensionInfo());
+ mpCBDisableAllExtensions->Enable(comphelper::BackupFileHelper::isTryDisableAllExtensionsPossible());
+ mpCBDeinstallUserExtensions->Enable(comphelper::BackupFileHelper::isTryDeinstallUserExtensionsPossible());
+ mpCBResetSharedExtensions->Enable(comphelper::BackupFileHelper::isTryResetSharedExtensionsPossible());
+ mpCBResetCustomizations->Enable(comphelper::BackupFileHelper::isTryResetCustomizationsPossible());
+
+ // no disable of mpCBResetWholeUserProfile, always possible (as last choice)
}
bool SafeModeDialog::Close()
@@ -248,10 +226,10 @@ void SafeModeDialog::applyChanges()
comphelper::BackupFileHelper::tryDeinstallUserExtensions();
}
- if (mpCBDeinstallAllExtensions->IsChecked())
+ if (mpCBResetSharedExtensions->IsChecked())
{
- // Deinstall all Extensions (user|shared|bundled)
- comphelper::BackupFileHelper::tryDeinstallAllExtensions();
+ // Reset shared Extensions
+ comphelper::BackupFileHelper::tryResetSharedExtensions();
}
}
@@ -432,7 +410,7 @@ IMPL_LINK(SafeModeDialog, CheckBoxHdl, CheckBox*, /*pCheckBox*/ )
mpCBCheckProfilesafeExtensions->IsChecked() ||
mpCBDisableAllExtensions->IsChecked() ||
mpCBDeinstallUserExtensions->IsChecked() ||
- mpCBDeinstallAllExtensions->IsChecked() ||
+ mpCBResetSharedExtensions->IsChecked() ||
mpCBDisableHWAcceleration->IsChecked() ||
mpCBResetCustomizations->IsChecked() ||
mpCBResetWholeUserProfile->IsChecked());
@@ -445,6 +423,8 @@ IMPL_LINK(SafeModeDialog, CheckBoxHdl, CheckBox*, /*pCheckBox*/ )
IMPL_LINK( SafeModeDialog, HandleHyperlink, FixedHyperlink*, pHyperlink )
{
SafeModeDialog::openWebBrowser( pHyperlink->GetURL(), GetText() );
+
+ return 0;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svx/source/dialog/SafeModeDialog.hxx b/svx/source/dialog/SafeModeDialog.hxx
index 5944357..91e4c66 100644
--- a/svx/source/dialog/SafeModeDialog.hxx
+++ b/svx/source/dialog/SafeModeDialog.hxx
@@ -51,7 +51,7 @@ private:
VclPtr<CheckBox> mpCBCheckProfilesafeExtensions;
VclPtr<CheckBox> mpCBDisableAllExtensions;
VclPtr<CheckBox> mpCBDeinstallUserExtensions;
- VclPtr<CheckBox> mpCBDeinstallAllExtensions;
+ VclPtr<CheckBox> mpCBResetSharedExtensions;
VclPtr<CheckBox> mpCBDisableHWAcceleration;
VclPtr<CheckBox> mpCBResetCustomizations;
VclPtr<CheckBox> mpCBResetWholeUserProfile;
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index 9a02c2a..feb5326 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!-- Generated with glade 3.18.3 -->
+<!-- Generated with glade 3.20.0 -->
<interface>
<requires lib="gtk+" version="3.12"/>
<object class="GtkDialog" id="SafeModeDialog">
@@ -231,7 +231,7 @@ The proposed changes get more radical from top down so it is recommended to try
</child>
<child>
<object class="GtkRadioButton" id="radio_deinstall">
- <property name="label" translatable="yes">Uninstall extensions</property>
+ <property name="label" translatable="yes">Extensions</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -268,8 +268,8 @@ The proposed changes get more radical from top down so it is recommended to try
</packing>
</child>
<child>
- <object class="GtkCheckButton" id="check_deinstall_all_extensions">
- <property name="label" translatable="yes">Uninstall all extensions (including shared and bundled)</property>
+ <object class="GtkCheckButton" id="check_reset_shared_extensions">
+ <property name="label" translatable="yes">Reset state of shared extensions</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
commit 827f79603dd85aa213959bd7780c5d131aa1598c
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Tue Dec 6 16:57:34 2016 +0100
SafeModeDialog: Could not activate checkboxes to remove extensions
Because of missing event handler
Change-Id: Id546a2b22a89321ca09ec29ba7787a1315753bcf
Reviewed-on: https://gerrit.libreoffice.org/31692
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index 8abe2ae..1eeb91c 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -90,6 +90,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpRadioRestore->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
mpRadioConfigure->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
+ mpRadioDeinstall->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
mpRadioReset->SetClickHdl(LINK(this, SafeModeDialog, RadioBtnHdl));
mpBtnContinue->SetClickHdl(LINK(this, SafeModeDialog, DialogBtnHdl));
commit 49a5e25d7a4139d6387dc63c8f3e7402c9b4744e
Author: Katarina Behrens <Katarina.Behrens at cib.de>
Date: Tue Nov 29 14:01:08 2016 +0100
safe mode: Add help button to the dialog
Change-Id: I5aa29ccf048dc6f7d927089cc3c9b8b39bf2893c
Reviewed-on: https://gerrit.libreoffice.org/31367
Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
Tested-by: Katarina Behrens <Katarina.Behrens at cib.de>
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index 07be015..9a02c2a 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -18,6 +18,21 @@
<property name="can_focus">False</property>
<property name="layout_style">end</property>
<child>
+ <object class="GtkButton" id="help">
+ <property name="label">gtk-help</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">True</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ <property name="secondary">True</property>
+ </packing>
+ </child>
+ <child>
<object class="GtkButton" id="btn_continue">
<property name="label" translatable="yes">_Continue in Safe Mode</property>
<property name="visible">True</property>
@@ -29,7 +44,7 @@
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
- <property name="position">0</property>
+ <property name="position">1</property>
</packing>
</child>
<child>
@@ -43,7 +58,7 @@
<packing>
<property name="expand">True</property>
<property name="fill">True</property>
- <property name="position">1</property>
+ <property name="position">2</property>
</packing>
</child>
<child>
commit 48fb59701315e25b1da276208e28c8d0bc6de927
Author: Katarina Behrens <Katarina.Behrens at cib.de>
Date: Tue Nov 29 00:28:17 2016 +0100
safe mode: typos and vocabulary nitpicking
Change-Id: I8ddeec03ea96eaca873136ccc3100577eba23939
Reviewed-on: https://gerrit.libreoffice.org/31335
Reviewed-by: Katarina Behrens <Katarina.Behrens at cib.de>
Tested-by: Katarina Behrens <Katarina.Behrens at cib.de>
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index 91d2373..07be015 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!-- Generated with glade 3.20.0 -->
+<!-- Generated with glade 3.18.3 -->
<interface>
<requires lib="gtk+" version="3.12"/>
<object class="GtkDialog" id="SafeModeDialog">
@@ -48,7 +48,7 @@
</child>
<child>
<object class="GtkButton" id="btn_restart">
- <property name="label" translatable="yes">_Make Changes and Restart</property>
+ <property name="label" translatable="yes">_Apply Changes and Restart</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
@@ -72,11 +72,11 @@
<object class="GtkLabel" id="label1">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">%PRODUCTNAME is now running in Safe Mode wich temporarily disables your configuration and extensions.
+ <property name="label" translatable="yes">%PRODUCTNAME is now running in safe mode which temporarily disables your user configuration and extensions.
-You can make one or more of the following changes to return to a working state.
+You can make one or more of the following changes to your user profile to return %PRODUCTNAME to a working state.
-The offered possible changes get more radical from top to bottom, so it is recommended to try them thoroughly one after the other.</property>
+The proposed changes get more radical from top down so it is recommended to try them successively one after another.</property>
<property name="wrap">True</property>
<property name="xalign">0</property>
<property name="yalign">0</property>
@@ -118,7 +118,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="orientation">vertical</property>
<child>
<object class="GtkCheckButton" id="check_profilesafe_config">
- <property name="label" translatable="yes">Restore user configuration to last known working state</property>
+ <property name="label" translatable="yes">Restore user configuration to the last known working state</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -133,7 +133,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkCheckButton" id="check_profilesafe_extensions">
- <property name="label" translatable="yes">Restore enabled/disabled state of installed user extensions to last known working state</property>
+ <property name="label" translatable="yes">Restore state of installed user extensions to the last known working state</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -216,7 +216,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkRadioButton" id="radio_deinstall">
- <property name="label" translatable="yes">Deinstall extensions</property>
+ <property name="label" translatable="yes">Uninstall extensions</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -239,7 +239,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="orientation">vertical</property>
<child>
<object class="GtkCheckButton" id="check_deinstall_user_extensions">
- <property name="label" translatable="yes">Deinstall all user extensions</property>
+ <property name="label" translatable="yes">Uninstall all user extensions</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -254,7 +254,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkCheckButton" id="check_deinstall_all_extensions">
- <property name="label" translatable="yes">Deinstall all extensions (including shared and bundled)</property>
+ <property name="label" translatable="yes">Uninstall all extensions (including shared and bundled)</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -314,7 +314,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkCheckButton" id="check_reset_whole_userprofile">
- <property name="label" translatable="yes">Reset the whole user profile</property>
+ <property name="label" translatable="yes">Reset entire user profile</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -356,7 +356,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<object class="GtkLabel" id="label3">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">If you experience problems that are not resolved by using the Safe Mode, visit the following link to get help or report a bug.</property>
+ <property name="label" translatable="yes">If you experience problems that are not resolved by using safe mode, visit the following link to get help or report a bug.</property>
<property name="xalign">0</property>
</object>
<packing>
@@ -383,7 +383,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<object class="GtkLabel" id="label4">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">You can also include the relevant parts of your User Profile. Beware that it might contain personal data.</property>
+ <property name="label" translatable="yes">You can also include relevant parts of your user profile in the bugreport (be aware it might contain personal data).</property>
<property name="xalign">0</property>
</object>
<packing>
@@ -399,7 +399,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="homogeneous">True</property>
<child>
<object class="GtkButton" id="btn_create_zip">
- <property name="label" translatable="yes">Create zip archive from User Profile</property>
+ <property name="label" translatable="yes">Create Zip Archive from User Profile</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">True</property>
commit 49621644e0aa079c0b8b84f7c36a1e206cf261ab
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Thu Nov 3 12:21:37 2016 +0100
SafeModeDialog: Improve description
Change-Id: I86f4a322f3d68caafcfe206e2d0f2164bc789bd8
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index fd6577c..91d2373 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -72,7 +72,9 @@
<object class="GtkLabel" id="label1">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">%PRODUCTNAME is now running in Safe Mode. You can make one or more of the following changes to return to a working state.
+ <property name="label" translatable="yes">%PRODUCTNAME is now running in Safe Mode wich temporarily disables your configuration and extensions.
+
+You can make one or more of the following changes to return to a working state.
The offered possible changes get more radical from top to bottom, so it is recommended to try them thoroughly one after the other.</property>
<property name="wrap">True</property>
commit 72bf021c21423c6de8c32ba7930455aa3a67db2e
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Thu Nov 3 12:11:12 2016 +0100
SafeModeDialog: Better grouping of options
Disable/Deinstall extensions are mutually exclusive, so group them appropriately
Change-Id: I6dc9c53ef4c18103c7521d494a769d522b0412dd
Reviewed-on: https://gerrit.libreoffice.org/30522
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index 2c98fa3..8abe2ae 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -42,10 +42,12 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
mpBoxRestore(),
mpBoxConfigure(),
+ mpBoxDeinstall(),
mpBoxReset(),
mpRadioRestore(),
mpRadioConfigure(),
+ mpRadioDeinstall(),
mpRadioReset(),
mpCBCheckProfilesafeConfig(),
@@ -65,10 +67,12 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
get(mpBoxRestore, "group_restore");
get(mpBoxConfigure, "group_configure");
+ get(mpBoxDeinstall, "group_deinstall");
get(mpBoxReset, "group_reset");
get(mpRadioRestore, "radio_restore");
get(mpRadioConfigure, "radio_configure");
+ get(mpRadioDeinstall, "radio_deinstall");
get(mpRadioReset, "radio_reset");
get(mpCBCheckProfilesafeConfig, "check_profilesafe_config");
@@ -110,6 +114,7 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
// Check the first radio button and disable the other parts
mpRadioRestore->Check();
mpBoxConfigure->Disable();
+ mpBoxDeinstall->Disable();
mpBoxReset->Disable();
// Set URL for help button (module=safemode)
@@ -129,10 +134,12 @@ void SafeModeDialog::dispose()
{
mpRadioRestore.clear();
mpRadioConfigure.clear();
+ mpRadioDeinstall.clear();
mpRadioReset.clear();
mpBoxRestore.clear();
mpBoxConfigure.clear();
+ mpBoxDeinstall.clear();
mpBoxReset.clear();
mpBtnContinue.clear();
@@ -226,6 +233,14 @@ void SafeModeDialog::applyChanges()
comphelper::BackupFileHelper::tryDisableAllExtensions();
}
+ if (mpCBDisableHWAcceleration->IsChecked())
+ {
+ comphelper::BackupFileHelper::tryDisableHWAcceleration();
+ }
+ }
+
+ if (mpRadioDeinstall->IsChecked())
+ {
if (mpCBDeinstallUserExtensions->IsChecked())
{
// Deinstall all User Extensions (installed for User only)
@@ -237,11 +252,6 @@ void SafeModeDialog::applyChanges()
// Deinstall all Extensions (user|shared|bundled)
comphelper::BackupFileHelper::tryDeinstallAllExtensions();
}
-
- if (mpCBDisableHWAcceleration->IsChecked())
- {
- comphelper::BackupFileHelper::tryDisableHWAcceleration();
- }
}
// Reset
@@ -267,7 +277,18 @@ void SafeModeDialog::applyChanges()
IMPL_LINK(SafeModeDialog, RadioBtnHdl, Button*, pBtn)
{
- if (pBtn == mpRadioConfigure.get())
+ if (pBtn == mpRadioRestore.get())
+ {
+ // Enable the currently selected box
+ mpBoxRestore->Enable();
+ // Make sure only possible choices are active
+ enableDisableWidgets();
+ // Disable the unselected boxes
+ mpBoxReset->Disable();
+ mpBoxConfigure->Disable();
+ mpBoxDeinstall->Disable();
+ }
+ else if (pBtn == mpRadioConfigure.get())
{
// Enable the currently selected box
mpBoxConfigure->Enable();
@@ -276,27 +297,30 @@ IMPL_LINK(SafeModeDialog, RadioBtnHdl, Button*, pBtn)
// Disable the unselected boxes
mpBoxRestore->Disable();
mpBoxReset->Disable();
+ mpBoxDeinstall->Disable();
}
- else if (pBtn == mpRadioReset.get())
+ else if (pBtn == mpRadioDeinstall.get())
{
// Enable the currently selected box
- mpBoxReset->Enable();
+ mpBoxDeinstall->Enable();
// Make sure only possible choices are active
enableDisableWidgets();
// Disable the unselected boxes
- mpBoxConfigure->Disable();
mpBoxRestore->Disable();
+ mpBoxConfigure->Disable();
+ mpBoxReset->Disable();
}
- else if (pBtn == mpRadioRestore.get())
+ else if (pBtn == mpRadioReset.get())
{
// Enable the currently selected box
- mpBoxRestore->Enable();
+ mpBoxReset->Enable();
// Make sure only possible choices are active
enableDisableWidgets();
// Disable the unselected boxes
- mpBoxReset->Disable();
mpBoxConfigure->Disable();
+ mpBoxRestore->Disable();
+ mpBoxDeinstall->Disable();
}
return 0;
diff --git a/svx/source/dialog/SafeModeDialog.hxx b/svx/source/dialog/SafeModeDialog.hxx
index d516094..5944357 100644
--- a/svx/source/dialog/SafeModeDialog.hxx
+++ b/svx/source/dialog/SafeModeDialog.hxx
@@ -39,10 +39,12 @@ private:
VclPtr<VclBox> mpBoxRestore;
VclPtr<VclBox> mpBoxConfigure;
+ VclPtr<VclBox> mpBoxDeinstall;
VclPtr<VclBox> mpBoxReset;
VclPtr<RadioButton> mpRadioRestore;
VclPtr<RadioButton> mpRadioConfigure;
+ VclPtr<RadioButton> mpRadioDeinstall;
VclPtr<RadioButton> mpRadioReset;
VclPtr<CheckBox> mpCBCheckProfilesafeConfig;
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index 68b35ff..fd6577c 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -112,7 +112,6 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="margin_left">18</property>
- <property name="margin_top">6</property>
<property name="margin_bottom">6</property>
<property name="orientation">vertical</property>
<child>
@@ -174,7 +173,6 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="margin_left">18</property>
- <property name="margin_top">6</property>
<property name="margin_bottom">6</property>
<property name="orientation">vertical</property>
<child>
@@ -193,8 +191,8 @@ The offered possible changes get more radical from top to bottom, so it is recom
</packing>
</child>
<child>
- <object class="GtkCheckButton" id="check_deinstall_user_extensions">
- <property name="label" translatable="yes">Deinstall all user extensions</property>
+ <object class="GtkCheckButton" id="check_disable_hw_acceleration">
+ <property name="label" translatable="yes">Disable hardware acceleration (OpenGL, OpenCL)</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -204,12 +202,42 @@ The offered possible changes get more radical from top to bottom, so it is recom
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">1</property>
+ <property name="position">3</property>
</packing>
</child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">3</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkRadioButton" id="radio_deinstall">
+ <property name="label" translatable="yes">Deinstall extensions</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">False</property>
+ <property name="xalign">0</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">radio_restore</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">4</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkBox" id="group_deinstall">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="margin_left">18</property>
+ <property name="margin_bottom">6</property>
+ <property name="orientation">vertical</property>
<child>
- <object class="GtkCheckButton" id="check_deinstall_all_extensions">
- <property name="label" translatable="yes">Deinstall all extensions (including shared and bundled)</property>
+ <object class="GtkCheckButton" id="check_deinstall_user_extensions">
+ <property name="label" translatable="yes">Deinstall all user extensions</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -219,12 +247,12 @@ The offered possible changes get more radical from top to bottom, so it is recom
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">2</property>
+ <property name="position">1</property>
</packing>
</child>
<child>
- <object class="GtkCheckButton" id="check_disable_hw_acceleration">
- <property name="label" translatable="yes">Disable hardware acceleration (OpenGL, OpenCL)</property>
+ <object class="GtkCheckButton" id="check_deinstall_all_extensions">
+ <property name="label" translatable="yes">Deinstall all extensions (including shared and bundled)</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -234,14 +262,14 @@ The offered possible changes get more radical from top to bottom, so it is recom
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">3</property>
+ <property name="position">2</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">3</property>
+ <property name="position">5</property>
</packing>
</child>
<child>
@@ -258,7 +286,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">4</property>
+ <property name="position">6</property>
</packing>
</child>
<child>
@@ -266,7 +294,6 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="margin_left">18</property>
- <property name="margin_top">6</property>
<property name="orientation">vertical</property>
<child>
<object class="GtkCheckButton" id="check_reset_customizations">
@@ -302,7 +329,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">5</property>
+ <property name="position">7</property>
</packing>
</child>
</object>
commit 087479e267d43ca7cf0db2823607828c4130c4d5
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Thu Nov 3 11:54:53 2016 +0100
SafeModeDialog: Improve labels
Change-Id: If90b25e569a8feaa86e5c43da5966d5314cf0f14
Reviewed-on: https://gerrit.libreoffice.org/30521
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index 43989aa..68b35ff 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -92,7 +92,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="orientation">vertical</property>
<child>
<object class="GtkRadioButton" id="radio_restore">
- <property name="label" translatable="yes">Restore</property>
+ <property name="label" translatable="yes">Restore from backup</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -117,7 +117,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="orientation">vertical</property>
<child>
<object class="GtkCheckButton" id="check_profilesafe_config">
- <property name="label" translatable="yes">Restore UserConfiguration to last known working state from backup</property>
+ <property name="label" translatable="yes">Restore user configuration to last known working state</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -132,7 +132,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkCheckButton" id="check_profilesafe_extensions">
- <property name="label" translatable="yes">Restore enable/disable State of installed User Extensions to last known working state</property>
+ <property name="label" translatable="yes">Restore enabled/disabled state of installed user extensions to last known working state</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -179,7 +179,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="orientation">vertical</property>
<child>
<object class="GtkCheckButton" id="check_disable_all_extensions">
- <property name="label" translatable="yes">Disable all User Extensions</property>
+ <property name="label" translatable="yes">Disable all user extensions</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -194,7 +194,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkCheckButton" id="check_deinstall_user_extensions">
- <property name="label" translatable="yes">Deinstall all User Extensions</property>
+ <property name="label" translatable="yes">Deinstall all user extensions</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -209,7 +209,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkCheckButton" id="check_deinstall_all_extensions">
- <property name="label" translatable="yes">Deinstall all Extensions (including shared and bundled)</property>
+ <property name="label" translatable="yes">Deinstall all extensions (including shared and bundled)</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -246,7 +246,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkRadioButton" id="radio_reset">
- <property name="label" translatable="yes">Reset</property>
+ <property name="label" translatable="yes">Reset to factory settings</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -270,7 +270,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<property name="orientation">vertical</property>
<child>
<object class="GtkCheckButton" id="check_reset_customizations">
- <property name="label" translatable="yes">Reset User Customizations (Settings, User Interface modifications, AutoCorrect, AutoText, etc.)</property>
+ <property name="label" translatable="yes">Reset user customizations (settings, user interface modifications, AutoCorrect, AutoText, etc.)</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
@@ -285,7 +285,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
</child>
<child>
<object class="GtkCheckButton" id="check_reset_whole_userprofile">
- <property name="label" translatable="yes">Reset the whole User Profile to initial state after Installation</property>
+ <property name="label" translatable="yes">Reset the whole user profile</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="receives_default">False</property>
commit da2e34e659d2441681dd242c0b6236fdbca0464f
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Thu Nov 3 11:33:47 2016 +0100
SafeModeDialog: Fix enabling/disabling of widgets
Change-Id: I7133b64f975fa8e68550d41056b689dfc18cf172
Reviewed-on: https://gerrit.libreoffice.org/30520
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/svx/source/dialog/SafeModeDialog.cxx b/svx/source/dialog/SafeModeDialog.cxx
index 4640bfb..2c98fa3 100644
--- a/svx/source/dialog/SafeModeDialog.cxx
+++ b/svx/source/dialog/SafeModeDialog.cxx
@@ -107,37 +107,6 @@ SafeModeDialog::SafeModeDialog(vcl::Window* pParent)
// Disable restart btn until some checkbox is active
mpBtnRestart->Disable();
- if (!maBackupFileHelper.isPopPossible())
- {
- mpCBCheckProfilesafeConfig->Disable();
- }
-
- if (!maBackupFileHelper.isPopPossibleExtensionInfo())
- {
- mpCBCheckProfilesafeExtensions->Disable();
- }
-
- if (!comphelper::BackupFileHelper::isTryDisableAllExtensionsPossible())
- {
- mpCBDisableAllExtensions->Disable();
- }
-
- if (!comphelper::BackupFileHelper::isTryDeinstallUserExtensionsPossible())
- {
- mpCBDeinstallUserExtensions->Disable();
- }
-
- if (!comphelper::BackupFileHelper::isTryDeinstallAllExtensionsPossible())
- {
- mpCBDeinstallAllExtensions->Disable();
- }
-
- if (!comphelper::BackupFileHelper::isTryResetCustomizationsPossible())
- {
- mpCBResetCustomizations->Disable();
- }
- // no disabe of mpCBResetWholeUserProfile, always possible (as last choice)
-
// Check the first radio button and disable the other parts
mpRadioRestore->Check();
mpBoxConfigure->Disable();
@@ -186,6 +155,40 @@ void SafeModeDialog::dispose()
Dialog::dispose();
}
+void SafeModeDialog::enableDisableWidgets()
+{
+ if (!maBackupFileHelper.isPopPossible())
+ {
+ mpCBCheckProfilesafeConfig->Disable();
+ }
+
+ if (!maBackupFileHelper.isPopPossibleExtensionInfo())
+ {
+ mpCBCheckProfilesafeExtensions->Disable();
+ }
+
+ if (!comphelper::BackupFileHelper::isTryDisableAllExtensionsPossible())
+ {
+ mpCBDisableAllExtensions->Disable();
+ }
+
+ if (!comphelper::BackupFileHelper::isTryDeinstallUserExtensionsPossible())
+ {
+ mpCBDeinstallUserExtensions->Disable();
+ }
+
+ if (!comphelper::BackupFileHelper::isTryDeinstallAllExtensionsPossible())
+ {
+ mpCBDeinstallAllExtensions->Disable();
+ }
+
+ if (!comphelper::BackupFileHelper::isTryResetCustomizationsPossible())
+ {
+ mpCBResetCustomizations->Disable();
+ }
+ // no disabe of mpCBResetWholeUserProfile, always possible (as last choice)
+}
+
bool SafeModeDialog::Close()
{
// Remove the safe mode flag before exiting this dialog
@@ -266,19 +269,32 @@ IMPL_LINK(SafeModeDialog, RadioBtnHdl, Button*, pBtn)
{
if (pBtn == mpRadioConfigure.get())
{
+ // Enable the currently selected box
mpBoxConfigure->Enable();
+ // Make sure only possible choices are active
+ enableDisableWidgets();
+ // Disable the unselected boxes
mpBoxRestore->Disable();
mpBoxReset->Disable();
+
}
else if (pBtn == mpRadioReset.get())
{
+ // Enable the currently selected box
mpBoxReset->Enable();
+ // Make sure only possible choices are active
+ enableDisableWidgets();
+ // Disable the unselected boxes
mpBoxConfigure->Disable();
mpBoxRestore->Disable();
}
else if (pBtn == mpRadioRestore.get())
{
+ // Enable the currently selected box
mpBoxRestore->Enable();
+ // Make sure only possible choices are active
+ enableDisableWidgets();
+ // Disable the unselected boxes
mpBoxReset->Disable();
mpBoxConfigure->Disable();
}
diff --git a/svx/source/dialog/SafeModeDialog.hxx b/svx/source/dialog/SafeModeDialog.hxx
index a5d719d..d516094 100644
--- a/svx/source/dialog/SafeModeDialog.hxx
+++ b/svx/source/dialog/SafeModeDialog.hxx
@@ -61,6 +61,7 @@ private:
// local BackupFileHelper for handling possible restores
comphelper::BackupFileHelper maBackupFileHelper;
+ void enableDisableWidgets();
void applyChanges();
static void openWebBrowser(const OUString & sURL, const OUString &sTitle);
commit bf5c49e19db5284e96bdf199fd85e457b5cb787f
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Thu Nov 3 09:26:02 2016 +0100
SafeMode: Add indicator to window title when in Safe Mode
Change-Id: I1d8350315768093b4c4af1cd8b732602c5217edb
Reviewed-on: https://gerrit.libreoffice.org/30518
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/framework/inc/classes/resource.hrc b/framework/inc/classes/resource.hrc
index 8d23371..c939e48 100644
--- a/framework/inc/classes/resource.hrc
+++ b/framework/inc/classes/resource.hrc
@@ -50,6 +50,7 @@
#define STR_CLEAR_RECENT_FILES (RID_STR_START+23)
#define STR_CLEAR_RECENT_FILES_HELP (RID_STR_START+24)
#define STR_LANGSTATUS_HINT (RID_STR_START+25)
+#define STR_SAFEMODE_TITLE (RID_STR_START+26)
#define POPUPMENU_TOOLBAR_QUICKCUSTOMIZATION (RID_MENU_START+0)
diff --git a/framework/source/classes/resource.src b/framework/source/classes/resource.src
index c54eaa3..7b3164a 100644
--- a/framework/source/classes/resource.src
+++ b/framework/source/classes/resource.src
@@ -114,6 +114,11 @@ String STR_CLEAR_RECENT_FILES_HELP
Text [ en-US ] = "Clears the list with the most recently opened files. This action can not be undone.";
};
+String STR_SAFEMODE_TITLE
+{
+ Text [ en-US ] = " (Safe Mode)";
+};
+
String STR_TOOLBAR_TITLE_ADDON
{
Text [ en-US ] = "Add-On %num%";
diff --git a/framework/source/fwe/helper/titlehelper.cxx b/framework/source/fwe/helper/titlehelper.cxx
index d8c44d3..1d6a73c 100644
--- a/framework/source/fwe/helper/titlehelper.cxx
+++ b/framework/source/fwe/helper/titlehelper.cxx
@@ -20,6 +20,8 @@
#include <framework/titlehelper.hxx>
#include <services.h>
#include <properties.h>
+#include <classes/fwkresid.hxx>
+#include <classes/resource.hrc>
#include <com/sun/star/frame/UntitledNumbersConst.hpp>
#include <com/sun/star/frame/XStorable.hpp>
@@ -34,6 +36,7 @@
#include <rtl/ustrbuf.hxx>
#include <osl/mutex.hxx>
#include <tools/urlobj.hxx>
+#include <vcl/svapp.hxx>
namespace framework{
@@ -475,6 +478,7 @@ void TitleHelper::impl_updateTitleForFrame (const css::uno::Reference< css::fram
impl_appendModuleName (sTitle);
impl_appendDebugVersion (sTitle);
#endif
+ impl_appendSafeMode (sTitle);
// SYNCHRONIZED ->
aLock.reset ();
@@ -560,6 +564,12 @@ void TitleHelper::impl_appendDebugVersion (OUStringBuffer&)
}
#endif
+void TitleHelper::impl_appendSafeMode (OUStringBuffer& sTitle)
+{
+ if (Application::IsSafeModeEnabled())
+ sTitle.append(FwkResId (STR_SAFEMODE_TITLE));
+}
+
void TitleHelper::impl_startListeningForModel (const css::uno::Reference< css::frame::XModel >& xModel)
{
css::uno::Reference< css::document::XDocumentEventBroadcaster > xBroadcaster(xModel, css::uno::UNO_QUERY);
diff --git a/include/framework/titlehelper.hxx b/include/framework/titlehelper.hxx
index a1653d7..5d5219c 100644
--- a/include/framework/titlehelper.hxx
+++ b/include/framework/titlehelper.hxx
@@ -161,6 +161,7 @@ class FWE_DLLPUBLIC TitleHelper : private ::cppu::BaseMutex
void impl_appendProductExtension (OUStringBuffer& sTitle);
void impl_appendModuleName (OUStringBuffer& sTitle);
void impl_appendDebugVersion (OUStringBuffer& sTitle);
+ void impl_appendSafeMode (OUStringBuffer& sTitle);
void impl_setSubTitle (const css::uno::Reference< css::frame::XTitle >& xSubTitle);
commit 6b362bb18dd68b29049f805e8d494ad9dc7a11df
Author: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Date: Wed Nov 2 10:26:39 2016 +0100
SafeModeDialog: Allow to create zip file from profile
Change-Id: I4296d1cf5058be359ffed46745673cf26eba3375
Reviewed-on: https://gerrit.libreoffice.org/30479
Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
Tested-by: Samuel Mehrbrodt <Samuel.Mehrbrodt at cib.de>
diff --git a/comphelper/source/misc/backupfilehelper.cxx b/comphelper/source/misc/backupfilehelper.cxx
index c0e7aba..208fb4b 100644
--- a/comphelper/source/misc/backupfilehelper.cxx
+++ b/comphelper/source/misc/backupfilehelper.cxx
@@ -2211,6 +2211,11 @@ namespace comphelper
return maUserConfigBaseURL;
}
+ const OUString& BackupFileHelper::getUserProfileWorkURL()
+ {
+ return maUserConfigWorkURL;
+ }
+
/////////////////// helpers ///////////////////////
const rtl::OUString BackupFileHelper::getPackURL()
diff --git a/include/comphelper/backupfilehelper.hxx b/include/comphelper/backupfilehelper.hxx
index 4d7b153..e9b4183 100644
--- a/include/comphelper/backupfilehelper.hxx
+++ b/include/comphelper/backupfilehelper.hxx
@@ -182,6 +182,9 @@ namespace comphelper
/** Return the profile url */
static const OUString& getUserProfileURL();
+ /** Return the url of the backed up profile (when in safe mode) */
+ static const OUString& getUserProfileWorkURL();
+
private:
// internal helper methods
static const rtl::OUString getPackURL();
diff --git a/include/comphelper/package/ZipPackageHelper.hxx b/include/comphelper/package/ZipPackageHelper.hxx
new file mode 100644
index 0000000..2cdd5db
--- /dev/null
+++ b/include/comphelper/package/ZipPackageHelper.hxx
@@ -0,0 +1,57 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+#ifndef INCLUDED_COMPHELPER_PACKAGE_ZIPPACKAGEHELPER_HXX
+#define INCLUDED_COMPHELPER_PACKAGE_ZIPPACKAGEHELPER_HXX
+
+#include <com/sun/star/container/XHierarchicalNameAccess.hpp>
+#include <com/sun/star/lang/XSingleServiceFactory.hpp>
+#include <com/sun/star/lang/XMultiServiceFactory.hpp>
+#include <com/sun/star/uno/XComponentContext.hpp>
+#include <com/sun/star/io/XInputStream.hpp>
+
+
+class ZipPackageHelper
+{
+public:
+ ZipPackageHelper( const css::uno::Reference< css::uno::XComponentContext >& rxContext,
+ const OUString& sPackageURL);
+
+ void savePackage();
+
+ void addFile( const OUString& rSourceFile )
+ throw( css::uno::Exception, std::exception );
+
+ void addStream( css::uno::Reference< css::io::XInputStream > const & xInput,
+ const OUString& aName ) throw( css::uno::Exception );
+
+ css::uno::Reference< css::uno::XInterface > addFolder( const OUString& rName )
+ throw( css::uno::Exception, std::exception );
+
+ void addFolderWithContent( const OUString& rDirURL );
+
+private:
+ css::uno::Reference< css::uno::XComponentContext > mxContext;
+ css::uno::Reference< css::container::XHierarchicalNameAccess > mxHNameAccess;
+ css::uno::Reference< css::lang::XSingleServiceFactory > mxFactory;
+ css::uno::Reference< css::uno::XInterface > mxRootFolder;
+};
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/svx/dialogs.hrc b/include/svx/dialogs.hrc
index 50d0d77..1a3b315 100644
--- a/include/svx/dialogs.hrc
+++ b/include/svx/dialogs.hrc
@@ -1098,8 +1098,11 @@
#define RID_SVXSTR_ZOOM_PAGE_WIDTH (RID_SVX_START + 1389)
#define RID_SVXSTR_ZOOM_OPTIMAL_VIEW (RID_SVX_START + 1390)
+// Strings for SafeModeDialog
+#define RID_SVXSTR_SAFEMODE_ZIP_FAILURE (RID_SVX_START + 1391)
+
// !!! IMPORTANT: consider and update RID_SVXSTR_NEXTFREE when introducing new RIDs for Strings !!!
-#define RID_SVXSTR_NEXTFREE (RID_SVX_START + 1391)
+#define RID_SVXSTR_NEXTFREE (RID_SVX_START + 1392)
// if we have _a_lot_ time, we should group the resource ids by type, instead
// of grouping them by semantics. The reason is that resource ids have to be
diff --git a/svx/AllLangResTarget_svx.mk b/svx/AllLangResTarget_svx.mk
index 70d165a..235fcb8 100644
--- a/svx/AllLangResTarget_svx.mk
+++ b/svx/AllLangResTarget_svx.mk
@@ -48,6 +48,7 @@ $(eval $(call gb_SrsTarget_add_files,svx/res,\
svx/source/dialog/passwd.src \
svx/source/dialog/prtqry.src \
svx/source/dialog/ruler.src \
+ svx/source/dialog/SafeMode.src \
svx/source/dialog/sdstring.src \
svx/source/dialog/srchdlg.src \
svx/source/dialog/svxbmpnumvalueset.src \
diff --git a/svx/UIConfig_svx.mk b/svx/UIConfig_svx.mk
index ae49d62..6ebec9d 100644
--- a/svx/UIConfig_svx.mk
+++ b/svx/UIConfig_svx.mk
@@ -47,6 +47,7 @@ $(eval $(call gb_UIConfig_add_uifiles,svx,\
svx/uiconfig/ui/optgridpage \
svx/uiconfig/ui/paralinespacingcontrol \
svx/uiconfig/ui/passwd \
+ svx/uiconfig/ui/profileexporteddialog \
svx/uiconfig/ui/querydeletecontourdialog \
svx/uiconfig/ui/querydeleteobjectdialog \
svx/uiconfig/ui/querydeletethemedialog \
diff --git a/svx/source/dialog/SafeMode.src b/svx/source/dialog/SafeMode.src
new file mode 100644
index 0000000..2de389e
--- /dev/null
+++ b/svx/source/dialog/SafeMode.src
@@ -0,0 +1,17 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include <svx/dialogs.hrc>
+
+String RID_SVXSTR_SAFEMODE_ZIP_FAILURE
+{
+ Text[en-US] = "The zip file could not be created.";
+};
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */
diff --git a/svx/source/dialog/SafeModeDialog.hxx b/svx/source/dialog/SafeModeDialog.hxx
index fd1a612..a5d719d 100644
--- a/svx/source/dialog/SafeModeDialog.hxx
+++ b/svx/source/dialog/SafeModeDialog.hxx
@@ -56,6 +56,7 @@ private:
VclPtr<FixedHyperlink> mpBugLink;
VclPtr<FixedHyperlink> mpUserProfileLink;
+ VclPtr<Button> mpBtnCreateZip;
// local BackupFileHelper for handling possible restores
comphelper::BackupFileHelper maBackupFileHelper;
@@ -65,7 +66,8 @@ private:
DECL_LINK(RadioBtnHdl, Button*);
DECL_LINK(CheckBoxHdl, CheckBox* );
- DECL_LINK(BtnHdl, Button*);
+ DECL_LINK(DialogBtnHdl, Button*);
+ DECL_LINK(CreateZipBtnHdl, Button*);
DECL_LINK(HandleHyperlink, FixedHyperlink*);
};
diff --git a/svx/uiconfig/ui/profileexporteddialog.ui b/svx/uiconfig/ui/profileexporteddialog.ui
new file mode 100644
index 0000000..3897bd5
--- /dev/null
+++ b/svx/uiconfig/ui/profileexporteddialog.ui
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.20.0 -->
+<interface>
+ <requires lib="gtk+" version="3.20"/>
+ <object class="GtkDialog" id="SafeModeQueryDialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">6</property>
+ <property name="title" translatable="yes">Enter Safe Mode</property>
+ <property name="resizable">False</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="dialog-vbox1">
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="close">
+ <property name="label">gtk-close</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_underline">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ <property name="secondary">True</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="openfolder">
+ <property name="label">Open Containing _Folder</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_underline">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLabel" id="label">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Your user profile has been exported as “libreoffice-profile.zip”.</property>
+ <property name="wrap">True</property>
+ <property name="max_width_chars">80</property>
+ <property name="lines">2</property>
+ <property name="xalign">0</property>
+ <property name="yalign">0</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="0">close</action-widget>
+ <action-widget response="0">openfolder</action-widget>
+ </action-widgets>
+ </object>
+</interface>
diff --git a/svx/uiconfig/ui/safemodedialog.ui b/svx/uiconfig/ui/safemodedialog.ui
index 74d32df..43989aa 100644
--- a/svx/uiconfig/ui/safemodedialog.ui
+++ b/svx/uiconfig/ui/safemodedialog.ui
@@ -354,8 +354,7 @@ The offered possible changes get more radical from top to bottom, so it is recom
<object class="GtkLabel" id="label4">
<property name="visible">True</property>
<property name="can_focus">False</property>
- <property name="label" translatable="yes">You can also include the relevant parts of your User Profile. Beware that it might contain personal data.
-Your User Profile is located at:</property>
+ <property name="label" translatable="yes">You can also include the relevant parts of your User Profile. Beware that it might contain personal data.</property>
<property name="xalign">0</property>
</object>
<packing>
@@ -365,17 +364,42 @@ Your User Profile is located at:</property>
</packing>
</child>
<child>
- <object class="GtkLinkButton" id="linkbutton_profile">
- <property name="label" translatable="yes">Show User Profile</property>
+ <object class="GtkBox">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="receives_default">True</property>
- <property name="relief">none</property>
+ <property name="can_focus">False</property>
+ <property name="homogeneous">True</property>
+ <child>
+ <object class="GtkButton" id="btn_create_zip">
+ <property name="label" translatable="yes">Create zip archive from User Profile</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkLinkButton" id="linkbutton_profile">
+ <property name="label" translatable="yes">Show User Profile</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="relief">none</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
... etc. - the rest is truncated
More information about the Libreoffice-commits
mailing list