Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/desktop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/generalsettings.cpp')
-rw-r--r--src/gui/generalsettings.cpp24
1 files changed, 16 insertions, 8 deletions
diff --git a/src/gui/generalsettings.cpp b/src/gui/generalsettings.cpp
index 419b5214b..4f9ec0d4c 100644
--- a/src/gui/generalsettings.cpp
+++ b/src/gui/generalsettings.cpp
@@ -29,6 +29,8 @@
#include "config.h"
+#include "legalnotice.h"
+
#include <QNetworkProxy>
#include <QDir>
#include <QScopedValueRollback>
@@ -53,14 +55,13 @@ GeneralSettings::GeneralSettings(QWidget *parent)
// setup about section
QString about = Theme::instance()->about();
- if (about.isEmpty()) {
- _ui->aboutGroupBox->hide();
- } else {
- _ui->aboutLabel->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::TextBrowserInteraction);
- _ui->aboutLabel->setText(about);
- _ui->aboutLabel->setWordWrap(true);
- _ui->aboutLabel->setOpenExternalLinks(true);
- }
+ _ui->aboutLabel->setTextInteractionFlags(Qt::TextSelectableByMouse | Qt::TextBrowserInteraction);
+ _ui->aboutLabel->setText(about);
+ _ui->aboutLabel->setWordWrap(true);
+ _ui->aboutLabel->setOpenExternalLinks(true);
+
+ // About legal notice
+ connect(_ui->legalNoticeButton, &QPushButton::clicked, this, &GeneralSettings::slotShowLegalNotice);
loadMiscSettings();
slotUpdateInfo();
@@ -192,4 +193,11 @@ void GeneralSettings::slotIgnoreFilesEditor()
}
}
+void GeneralSettings::slotShowLegalNotice()
+{
+ auto notice = new LegalNotice();
+ notice->exec();
+ delete notice;
+}
+
} // namespace OCC