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:
@@ -10,7 +10,7 @@
|
||||
#include "utility/messaging/type/MessageNewErrors.h"
|
||||
#include "utility/messaging/type/MessageStatus.h"
|
||||
#include "utility/text/TextAccess.h"
|
||||
#include "utility/TimePoint.h"
|
||||
#include "utility/TimeStamp.h"
|
||||
#include "utility/tracing.h"
|
||||
#include "utility/utility.h"
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#ifndef STORAGE_STATS_H
|
||||
#define STORAGE_STATS_H
|
||||
|
||||
#include "utility/TimePoint.h"
|
||||
#include "utility/TimeStamp.h"
|
||||
|
||||
struct StorageStats
|
||||
{
|
||||
@@ -20,7 +20,7 @@ struct StorageStats
|
||||
size_t completedFileCount;
|
||||
size_t fileLOCCount;
|
||||
|
||||
TimePoint timestamp;
|
||||
TimeStamp timestamp;
|
||||
};
|
||||
|
||||
#endif // STORAGE_STATS_H
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
#include "data/storage/sqlite/SqliteStorage.h"
|
||||
|
||||
#include "utility/logging/logging.h"
|
||||
#include "utility/TimePoint.h"
|
||||
#include "utility/TimeStamp.h"
|
||||
|
||||
SqliteStorage::SqliteStorage(const FilePath& dbFilePath)
|
||||
: m_dbFilePath(dbFilePath.canonical())
|
||||
@@ -127,12 +127,12 @@ bool SqliteStorage::isIncompatible() const
|
||||
|
||||
void SqliteStorage::setTime()
|
||||
{
|
||||
insertOrUpdateMetaValue("timestamp", TimePoint::now().toString());
|
||||
insertOrUpdateMetaValue("timestamp", TimeStamp::now().toString());
|
||||
}
|
||||
|
||||
TimePoint SqliteStorage::getTime() const
|
||||
TimeStamp SqliteStorage::getTime() const
|
||||
{
|
||||
return TimePoint(getMetaValue("timestamp"));
|
||||
return TimeStamp(getMetaValue("timestamp"));
|
||||
}
|
||||
|
||||
void SqliteStorage::setupMetaTable()
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
#include "utility/file/FilePath.h"
|
||||
|
||||
class SqliteStorageMigration;
|
||||
class TimePoint;
|
||||
class TimeStamp;
|
||||
|
||||
class SqliteStorage
|
||||
{
|
||||
@@ -43,7 +43,7 @@ public:
|
||||
bool isIncompatible() const;
|
||||
|
||||
void setTime();
|
||||
TimePoint getTime() const;
|
||||
TimeStamp getTime() const;
|
||||
|
||||
protected:
|
||||
void setupMetaTable();
|
||||
|
||||
Reference in New Issue
Block a user