mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-07 13:41:26 -07:00
Improvements on the behavior of the program updater(closes #1282):
1. Check for updates every hour 2. Don't check again for this session if the user chose to ignore the new version 3. Display a message if the user checked for updates via the menu item and there isn't one 4. Remove dead code
This commit is contained in:
parent
94df3f44d7
commit
4cbe3fd6f7
4 changed files with 25 additions and 80 deletions
|
@ -41,7 +41,7 @@ class ProgramUpdater : public QObject
|
|||
{
|
||||
Q_OBJECT
|
||||
public:
|
||||
explicit ProgramUpdater(QObject *parent = 0);
|
||||
explicit ProgramUpdater(QObject *parent = 0, bool invokedByUser = false);
|
||||
~ProgramUpdater();
|
||||
void checkForUpdates();
|
||||
void updateProgram();
|
||||
|
@ -52,17 +52,15 @@ protected:
|
|||
|
||||
protected slots:
|
||||
void rssDownloadFinished(QNetworkReply* reply);
|
||||
//void installUpdate(QString update_path);
|
||||
//void saveUpdate(QNetworkReply* reply);
|
||||
void setUpdateUrl(QString title);
|
||||
|
||||
signals:
|
||||
void updateCheckFinished(bool update_available, QString version);
|
||||
void updateInstallFinished(QString error);
|
||||
void updateCheckFinished(bool update_available, QString version, bool invokedByUser);
|
||||
|
||||
private:
|
||||
QString m_updateUrl;
|
||||
QNetworkAccessManager *mp_manager;
|
||||
bool m_invokedByUser;
|
||||
};
|
||||
|
||||
#endif // PROGRAMUPDATER_H
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue