Browse Source

chore(build): format code

reviewable/pr5747/r7
antony-jr 6 years ago
parent
commit
f4d9cff7d4
No known key found for this signature in database
GPG Key ID: 13089CB6F3D41A27
  1. 7
      src/net/updatecheck.cpp
  2. 2
      src/net/updatecheck.h
  3. 11
      src/widget/form/settings/aboutform.cpp

7
src/net/updatecheck.cpp

@ -27,13 +27,13 @@ @@ -27,13 +27,13 @@
#include <AppImageUpdaterBridge>
#include <AppImageUpdaterDialog>
#endif
#include <QDebug>
#include <QJsonDocument>
#include <QJsonObject>
#include <QRegularExpression>
#include <QNetworkReply>
#include <QObject>
#include <QRegularExpression>
#include <QTimer>
#include <QDebug>
#include <cassert>
#ifndef APPIMAGE_UPDATER_BRIDGE_ENABLED
@ -129,8 +129,7 @@ void UpdateCheck::handleResponse(QNetworkReply *reply) @@ -129,8 +129,7 @@ void UpdateCheck::handleResponse(QNetworkReply *reply)
qInfo() << "Update available to version" << latestVersion;
QUrl link{mainMap["html_url"].toString()};
emit updateAvailable(latestVersion, link);
}
else {
} else {
qInfo() << "qTox is up to date";
emit upToDate();
}

2
src/net/updatecheck.h

@ -16,8 +16,8 @@ @@ -16,8 +16,8 @@
You should have received a copy of the GNU General Public License
along with qTox. If not, see <http://www.gnu.org/licenses/>.
*/
#include <QObject>
#include <QNetworkAccessManager>
#include <QObject>
#include <QTimer>
#ifdef APPIMAGE_UPDATER_BRIDGE_ENABLED

11
src/widget/form/settings/aboutform.cpp

@ -20,12 +20,12 @@ @@ -20,12 +20,12 @@
#include "aboutform.h"
#include "ui_aboutsettings.h"
#include "src/widget/tool/recursivesignalblocker.h"
#include "src/net/updatecheck.h"
#include "src/widget/style.h"
#include "src/widget/translator.h"
#include "src/persistence/profile.h"
#include "src/persistence/settings.h"
#include "src/widget/style.h"
#include "src/widget/tool/recursivesignalblocker.h"
#include "src/widget/translator.h"
#include <tox/tox.h>
@ -173,9 +173,8 @@ void AboutForm::replaceVersions() @@ -173,9 +173,8 @@ void AboutForm::replaceVersions()
void AboutForm::onUpdateAvailable(QString latestVersion, QUrl link)
{
QObject::disconnect(linkConnection);
linkConnection = connect(bodyUI->updateAvailableButton, &QPushButton::clicked, [link](){
QDesktopServices::openUrl(link);
});
linkConnection = connect(bodyUI->updateAvailableButton, &QPushButton::clicked,
[link]() { QDesktopServices::openUrl(link); });
bodyUI->updateStack->setCurrentIndex(static_cast<int>(updateIndex::available));
}
#else

Loading…
Cancel
Save