mirror of
https://github.com/Sude-/lgogdownloader.git
synced 2024-11-20 11:49:17 +01:00
8e9c094929
Replace --update-check option with --updated and --notifications options --updated restricts downloader to operate only on games that have update flag set in account page --notifications shows the number of new forum replies, updates games, unread chat messages and pending friend requests --clear-update-flags clears update notification flags for all games Remove aliases for --game option "free" could no longer be used as originally intended and "all" was unnecessary because leaving regex empty has the same effect
38 lines
1.1 KiB
C++
38 lines
1.1 KiB
C++
/* This program is free software. It comes without any warranty, to
|
|
* the extent permitted by applicable law. You can redistribute it
|
|
* and/or modify it under the terms of the Do What The Fuck You Want
|
|
* To Public License, Version 2, as published by Sam Hocevar. See
|
|
* http://www.wtfpl.net/ for more details. */
|
|
|
|
#ifndef WEBSITE_H
|
|
#define WEBSITE_H
|
|
|
|
#include "config.h"
|
|
#include "util.h"
|
|
#include "globals.h"
|
|
#include <curl/curl.h>
|
|
#include <json/json.h>
|
|
#include <fstream>
|
|
|
|
class Website
|
|
{
|
|
public:
|
|
Website();
|
|
int Login(const std::string& email, const std::string& password);
|
|
std::string getResponse(const std::string& url);
|
|
Json::Value getGameDetailsJSON(const std::string& gameid);
|
|
std::vector<gameItem> getGames();
|
|
std::vector<wishlistItem> getWishlistItems();
|
|
bool IsLoggedIn();
|
|
virtual ~Website();
|
|
protected:
|
|
private:
|
|
static size_t writeMemoryCallback(char *ptr, size_t size, size_t nmemb, void *userp);
|
|
CURL* curlhandle;
|
|
bool IsloggedInSimple();
|
|
bool IsLoggedInComplex(const std::string& email);
|
|
int retries;
|
|
};
|
|
|
|
#endif // WEBSITE_H
|