mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-22 23:05:36 +08:00
Ref T41, download auto info triggered in mapping tool
This commit is contained in:
committed by
Mathew Sutcliffe
parent
b2d95f471e
commit
83adc66ec7
@@ -113,7 +113,7 @@ void CSwiftData::init()
|
||||
this->setWindowTitle(t);
|
||||
}
|
||||
|
||||
QTimer::singleShot(10 * 1000, this, &CSwiftData::checkNewVersion);
|
||||
sGui->triggerNewVersionCheck(10 * 1000);
|
||||
emit sGui->startUpCompleted(true);
|
||||
}
|
||||
|
||||
@@ -151,21 +151,6 @@ void CSwiftData::performGracefulShutdown()
|
||||
// void
|
||||
}
|
||||
|
||||
void CSwiftData::checkNewVersion()
|
||||
{
|
||||
const QStringList channelPlatform = m_distributionSettings.get();
|
||||
Q_ASSERT_X(channelPlatform.size() == 2, Q_FUNC_INFO, "wrong setting");
|
||||
const QVersionNumber v = m_distributionInfo.get().getQVersionForChannelAndPlatform(channelPlatform);
|
||||
if (v.isNull() || v.segmentCount() < 4) return;
|
||||
const QVersionNumber vCurrent = CBuildConfig::getVersion();
|
||||
if (v <= vCurrent) return;
|
||||
|
||||
// new version
|
||||
const CStatusMessage m = CStatusMessage(this).info("New version '%1' from %2 for %3. Current version is '%4'") << v.toString() << channelPlatform.first() << channelPlatform.last() << vCurrent.toString();
|
||||
this->displayInOverlayWindow(m, 5000);
|
||||
CLogMessage::preformatted(m);
|
||||
}
|
||||
|
||||
void CSwiftData::displayConsole()
|
||||
{
|
||||
ui->comp_MainInfoArea->displayConsole();
|
||||
|
||||
@@ -14,9 +14,6 @@
|
||||
|
||||
#include "blackgui/mainwindowaccess.h"
|
||||
#include "blackgui/managedstatusbar.h"
|
||||
#include "blackmisc/datacache.h"
|
||||
#include "blackmisc/db/distributionlist.h"
|
||||
#include "blackmisc/settingscache.h"
|
||||
#include "blackmisc/identifiable.h"
|
||||
#include "blackmisc/statusmessage.h"
|
||||
|
||||
@@ -69,16 +66,14 @@ private:
|
||||
void initStyleSheet();
|
||||
void initMenu();
|
||||
void initDynamicMenus();
|
||||
|
||||
void performGracefulShutdown();
|
||||
void checkNewVersion();
|
||||
|
||||
void displayConsole();
|
||||
void displayLog();
|
||||
|
||||
QScopedPointer<Ui::CSwiftData> ui;
|
||||
BlackGui::CManagedStatusBar m_statusBar;
|
||||
BlackMisc::CDataReadOnly<BlackMisc::Db::TDistributionInfo> m_distributionInfo { this }; //!< version cache
|
||||
BlackMisc::CSettingReadOnly<BlackMisc::Db::TDistributionSetting> m_distributionSettings { this }; //!< channel/platform selected
|
||||
QScopedPointer<Ui::CSwiftData> ui;
|
||||
};
|
||||
|
||||
#endif // guard
|
||||
|
||||
Reference in New Issue
Block a user