Blame toonz/sources/include/toonzqt/updatechecker.h
|
Shinya Kitaoka |
810553 |
#pragma once
|
|
Shinya Kitaoka |
810553 |
|
|
Toshihiro Shimizu |
890ddd |
#ifndef UPDATE_CHECKER_H
|
|
Toshihiro Shimizu |
890ddd |
#define UPDATE_CHECKER_H
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#include <qtglobal></qtglobal>
|
|
Toshihiro Shimizu |
890ddd |
#include <qobject></qobject>
|
|
Toshihiro Shimizu |
890ddd |
#include "tcommon.h"
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#include <qnetworkaccessmanager></qnetworkaccessmanager>
|
|
Toshihiro Shimizu |
890ddd |
#include <qurl></qurl>
|
|
Toshihiro Shimizu |
890ddd |
#include <qstring></qstring>
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
#undef DVAPI
|
|
Toshihiro Shimizu |
890ddd |
#undef DVVAR
|
|
Toshihiro Shimizu |
890ddd |
#ifdef TOONZQT_EXPORTS
|
|
Toshihiro Shimizu |
890ddd |
#define DVAPI DV_EXPORT_API
|
|
Toshihiro Shimizu |
890ddd |
#define DVVAR DV_EXPORT_VAR
|
|
Toshihiro Shimizu |
890ddd |
#else
|
|
Toshihiro Shimizu |
890ddd |
#define DVAPI DV_IMPORT_API
|
|
Toshihiro Shimizu |
890ddd |
#define DVVAR DV_IMPORT_VAR
|
|
Toshihiro Shimizu |
890ddd |
#endif
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
class DVAPI UpdateChecker : public QObject {
|
|
Shinya Kitaoka |
120a6e |
Q_OBJECT
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
QSharedPointer<qnetworkaccessmanager> manager_;</qnetworkaccessmanager>
|
|
Shinya Kitaoka |
7be7e6 |
|
|
Shinya Kitaoka |
120a6e |
QString m_latestVersion;
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
public:
|
|
Shinya Kitaoka |
120a6e |
UpdateChecker(QUrl const& updateUrl);
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
QString getLatestVersion() const { return m_latestVersion; }
|
|
Toshihiro Shimizu |
890ddd |
|
|
Toshihiro Shimizu |
890ddd |
protected slots:
|
|
Shinya Kitaoka |
120a6e |
void httpRequestFinished(QNetworkReply*);
|
|
Shinya Kitaoka |
7be7e6 |
|
|
Shinya Kitaoka |
7be7e6 |
signals:
|
|
Shinya Kitaoka |
120a6e |
void done(bool error);
|
|
Toshihiro Shimizu |
890ddd |
};
|
|
Toshihiro Shimizu |
890ddd |
|
|
Shinya Kitaoka |
120a6e |
#endif // UPDATE_CHECKER_H
|