Files
GDevelop/IDE/UpdateChecker.h
T
2015-08-23 16:36:25 +02:00

55 lines
1.3 KiB
C++

/*
* GDevelop IDE
* Copyright 2008-2015 Florian Rival (Florian.Rival@gmail.com). All rights reserved.
* This project is released under the GNU General Public License version 3.
*/
#ifndef UPDATECHECKER_H
#define UPDATECHECKER_H
#include <string>
#include "GDCore/String.h"
/**
* \brief Class to download and retrieve information
* about GDevelop updates
*/
class UpdateChecker
{
public:
static UpdateChecker *Get();
static void DestroySingleton();
/**
* Download the information from the official website.
* \param excludeFromStatistics If set to true, the request asks the website not to take into account the request into statistics.
*/
void DownloadInformation(bool excludeFromStatistics = false);
bool newVersionAvailable;
int newMajor;
int newMinor;
int newBuild;
int newRevision;
gd::String info;
gd::String link;
gd::String news;
gd::String newsLinkLabel1;
gd::String newsLinkLabel2;
gd::String newsLink1;
gd::String newsLink2;
private:
/**
* \brief Default constructor
*/
UpdateChecker() : newVersionAvailable(false), newMajor(0), newMinor(0), newBuild(0), newRevision(0) {};
virtual ~UpdateChecker() {};
static UpdateChecker *_singleton;
};
#endif // UPDATECHECKER_H