From: Claudio Cambra Date: Wed, 23 Mar 2022 08:56:11 +0000 (+0100) Subject: Fix macOS autoupdater X-Git-Tag: archive/raspbian/3.16.7-1_deb13u1+rpi1~1^2~12^2~17^2~41^2~1 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=22e42ac6d383eccaf17d521d39b29c7f355687ab;p=nextcloud-desktop.git Fix macOS autoupdater Signed-off-by: Claudio Cambra --- diff --git a/VERSION.cmake b/VERSION.cmake index df35bb3ab..66875f1b1 100644 --- a/VERSION.cmake +++ b/VERSION.cmake @@ -2,6 +2,7 @@ set( MIRALL_VERSION_MAJOR 3 ) set( MIRALL_VERSION_MINOR 4 ) set( MIRALL_VERSION_PATCH 83 ) set( MIRALL_VERSION_YEAR 2022 ) + set( MIRALL_SOVERSION 0 ) # Minimum supported server version according to https://docs.nextcloud.com/server/latest/admin_manual/release_schedule.html diff --git a/src/gui/generalsettings.cpp b/src/gui/generalsettings.cpp index b03282c75..20df5809e 100644 --- a/src/gui/generalsettings.cpp +++ b/src/gui/generalsettings.cpp @@ -301,6 +301,7 @@ void GeneralSettings::slotUpdateInfo() else if (auto sparkleUpdater = qobject_cast(Updater::instance())) { _ui->updateStateLabel->setText(sparkleUpdater->statusString()); _ui->restartButton->setVisible(false); + connect(_ui->updateButton, &QAbstractButton::clicked, this, &GeneralSettings::slotUpdateCheckNow, Qt::UniqueConnection); } #endif @@ -389,7 +390,11 @@ void GeneralSettings::slotUpdateChannelChanged(const QString &translatedChannel) void GeneralSettings::slotUpdateCheckNow() { +#if defined(Q_OS_MAC) && defined(HAVE_SPARKLE) + auto *updater = qobject_cast(Updater::instance()); +#else auto *updater = qobject_cast(Updater::instance()); +#endif if (ConfigFile().skipUpdateCheck()) { updater = nullptr; // don't show update info if updates are disabled }