logic: Added update checker connecting to online API

* connects to https://www.sourcetrail.com/api/v1/versions/latest
* sends information about OS, platform, license type, current version and a unique user token
* Automatic update check is enabled via Startscreen and performed once every 24 hours on window focus
* Update check can be forced by clicking on "check for new version" on start screen
* renamed TimePoint to TimeStamp

fortune cookie message = In Träumen und im Leben ist nichts unmöglich.
This commit is contained in:
Eberhard Graether
2017-08-08 14:18:14 +02:00
parent db1c3b3f40
commit ff65a3f285
67 changed files with 680 additions and 251 deletions
@@ -10,7 +10,7 @@ TaskDecoratorDelay::TaskDecoratorDelay(size_t delayMS)
void TaskDecoratorDelay::doEnter(std::shared_ptr<Blackboard> blackboard)
{
m_start = TimePoint::now();
m_start = TimeStamp::now();
}
Task::TaskState TaskDecoratorDelay::doUpdate(std::shared_ptr<Blackboard> blackboard)
@@ -23,7 +23,7 @@ Task::TaskState TaskDecoratorDelay::doUpdate(std::shared_ptr<Blackboard> blackbo
const int SLEEP_TIME_MS = 25;
std::this_thread::sleep_for(std::chrono::microseconds(SLEEP_TIME_MS));
m_delayComplete = (TimePoint::now().deltaMS(m_start) >= m_delayMS);
m_delayComplete = (TimeStamp::now().deltaMS(m_start) >= m_delayMS);
return Task::STATE_HOLD;
}
@@ -5,7 +5,7 @@
#include "utility/scheduling/TaskDecorator.h"
#include "utility/scheduling/TaskRunner.h"
#include "utility/TimePoint.h"
#include "utility/TimeStamp.h"
class TaskDecoratorDelay
: public TaskDecorator
@@ -22,7 +22,7 @@ private:
const size_t m_delayMS;
TimePoint m_start;
TimeStamp m_start;
bool m_delayComplete;
};