更新 'src/GUI/UpdateChecker.cxx'
This commit is contained in:
parent
968051a12a
commit
8a82faeb28
@ -114,7 +114,7 @@ UpdateChecker::UpdateChecker(QObject *parent) : QObject(parent)
|
|||||||
_majorMinorVersion = versionParts[0] + "." + versionParts[1];
|
_majorMinorVersion = versionParts[0] + "." + versionParts[1];
|
||||||
|
|
||||||
// definitiely want to ensure HTTPS for this.
|
// definitiely want to ensure HTTPS for this.
|
||||||
std::string uri = "https://download.flightgear.org/builds/" + _majorMinorVersion + "/updates.xml";
|
std::string uri = "https://download.jingweiht.com/builds/" + _majorMinorVersion + "/updates.xml";
|
||||||
|
|
||||||
SG_LOG(SG_IO, SG_WARN, "UpdateChecker() " << uri );
|
SG_LOG(SG_IO, SG_WARN, "UpdateChecker() " << uri );
|
||||||
|
|
||||||
@ -166,10 +166,11 @@ void UpdateChecker::receivedUpdateXML(QByteArray body)
|
|||||||
|
|
||||||
SG_LOG(SG_IO, SG_WARN, "UpdateChecker() " << buffer );
|
SG_LOG(SG_IO, SG_WARN, "UpdateChecker() " << buffer );
|
||||||
|
|
||||||
const QDate n = QDate::currentDate().addDays(7);
|
// const QDate n = QDate::currentDate().addDays(7);
|
||||||
settings.setValue("next-update-check", n);
|
// settings.setValue("next-update-check", n);
|
||||||
|
|
||||||
const std::string newMajorVersion = props->getStringValue("current-major-release");
|
const std::string newMajorVersion = props->getStringValue("current-major-release");
|
||||||
|
|
||||||
if (simgear::strutils::compare_versions(FLIGHTGEAR_VERSION, newMajorVersion) < 0) {
|
if (simgear::strutils::compare_versions(FLIGHTGEAR_VERSION, newMajorVersion) < 0) {
|
||||||
// we have a newer version!
|
// we have a newer version!
|
||||||
_currentUpdateVersion = QString::fromStdString(newMajorVersion);
|
_currentUpdateVersion = QString::fromStdString(newMajorVersion);
|
||||||
|
Loading…
Reference in New Issue
Block a user