mirror of
https://github.com/overte-org/overte.git
synced 2025-04-21 17:03:58 +02:00
move checkForUpdates to menu to have option in menu
This commit is contained in:
parent
54d637119f
commit
65a63fb73e
3 changed files with 12 additions and 7 deletions
|
@ -64,7 +64,6 @@
|
|||
#include "renderer/ProgramObject.h"
|
||||
#include "ui/TextRenderer.h"
|
||||
#include "Swatch.h"
|
||||
#include "fvupdater.h"
|
||||
|
||||
using namespace std;
|
||||
|
||||
|
@ -209,16 +208,14 @@ Application::Application(int& argc, char** argv, timeval &startup_time) :
|
|||
NodeList::getInstance()->startSilentNodeRemovalThread();
|
||||
|
||||
_window->setCentralWidget(_glWidget);
|
||||
|
||||
#if defined(Q_OS_MAC) && defined(QT_NO_DEBUG)
|
||||
// if this is a release OS X build use fervor to check for an update
|
||||
FvUpdater::sharedUpdater()->SetFeedURL("https://s3-us-west-1.amazonaws.com/highfidelity/appcast.xml");
|
||||
FvUpdater::sharedUpdater()->CheckForUpdatesSilent();
|
||||
#endif
|
||||
|
||||
// call Menu getInstance static method to set up the menu
|
||||
_window->setMenuBar(Menu::getInstance());
|
||||
|
||||
#if defined(Q_OS_MAC) && defined(QT_NO_DEBUG)
|
||||
Menu::getInstance()->checkForUpdates();
|
||||
#endif
|
||||
|
||||
_networkAccessManager = new QNetworkAccessManager(this);
|
||||
|
||||
QRect available = desktop()->availableGeometry();
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#include <QStandardPaths>
|
||||
|
||||
#include "Application.h"
|
||||
#include "fvupdater.h"
|
||||
#include "PairingHandler.h"
|
||||
#include "Menu.h"
|
||||
#include "Util.h"
|
||||
|
@ -459,6 +460,12 @@ void Menu::exportSettings() {
|
|||
}
|
||||
}
|
||||
|
||||
void Menu::checkForUpdates() {
|
||||
qDebug() << "Checking if there are available updates.\n";
|
||||
// if this is a release OS X build use fervor to check for an update
|
||||
FvUpdater::sharedUpdater()->SetFeedURL("https://s3-us-west-1.amazonaws.com/highfidelity/appcast.xml");
|
||||
FvUpdater::sharedUpdater()->CheckForUpdatesSilent();
|
||||
}
|
||||
|
||||
void Menu::loadAction(QSettings* set, QAction* action) {
|
||||
if (action->isChecked() != set->value(action->text(), action->isChecked()).toBool()) {
|
||||
|
|
|
@ -58,6 +58,7 @@ public slots:
|
|||
void saveSettings(QSettings* settings = NULL);
|
||||
void importSettings();
|
||||
void exportSettings();
|
||||
void checkForUpdates();
|
||||
|
||||
private slots:
|
||||
void editPreferences();
|
||||
|
|
Loading…
Reference in a new issue