blob: 9244b74b9ced0f2a97d07ba533d11aed677c1642 (
plain) (
tree)
|
|
#ifndef TRACKER_CONFIG_H_36CDD648
#define TRACKER_CONFIG_H_36CDD648
#include <deque>
#include <string>
#include <utility>
struct ConnectionDetails {
std::string ap_server;
std::string ap_player;
std::string ap_password;
bool operator!=(const ConnectionDetails& rhs) const {
return std::tie(ap_server, ap_player, ap_password) != std::tie(rhs.ap_server, rhs.ap_player, rhs.ap_password);
}
};
class TrackerConfig {
public:
explicit TrackerConfig(const std::string& filename) : filename_(filename) {}
void Load();
void Save();
ConnectionDetails connection_details;
bool asked_to_check_for_updates = false;
bool should_check_for_updates = false;
bool hybrid_areas = false;
bool show_hunt_panels = false;
std::deque<ConnectionDetails> connection_history;
std::string ipc_address;
private:
std::string filename_;
};
TrackerConfig& GetTrackerConfig();
#endif /* end of include guard: TRACKER_CONFIG_H_36CDD648 */
|