blob: 5fa55066d7431864c5ab2acfb088c39dfd6a95ff (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
// -*- mode: c++; c-basic-offset: 2; -*-
#include "common.hh"
#include "gui_config.hh"
#include <string.h>
bool GuiConfig::load_name(std::string const& UNUSED(name)) {
return false;
}
bool GuiConfig::load_file(std::string const& UNUSED(filename)) {
return false;
}
bool GuiConfig::get(std::string const& key, bool fallback) {
auto ret = static_cast<Config*>(this)->get(key, nullptr);
if (!ret) return fallback;
return strcmp(ret, "true") == 0;
}
bool GuiConfig::good() const {
return true;
}
std::string const& GuiConfig::last_error() const {
return EMPTY;
}
// static
std::string const GuiConfig::EMPTY;
|