Enable web services on Android in Github build (#6555)
* Enable web services in android * Fix web services build on android * clang-format * Remove unnecessary line * Set telemetry to be disabled by default on all platforms
This commit is contained in:
parent
2281bf5b0b
commit
72b82ef6ed
@ -106,7 +106,6 @@ android {
|
||||
cmake {
|
||||
arguments "-DENABLE_QT=0", // Don't use QT
|
||||
"-DENABLE_SDL2=0", // Don't use SDL
|
||||
"-DENABLE_WEB_SERVICE=0", // Don't use telemetry
|
||||
"-DANDROID_ARM_NEON=true", // cryptopp requires Neon to work
|
||||
"-DBUNDLE_SPEEX=ON"
|
||||
|
||||
|
@ -274,7 +274,7 @@ void Config::ReadValues() {
|
||||
|
||||
// Web Service
|
||||
NetSettings::values.enable_telemetry =
|
||||
sdl2_config->GetBoolean("WebService", "enable_telemetry", true);
|
||||
sdl2_config->GetBoolean("WebService", "enable_telemetry", false);
|
||||
NetSettings::values.web_api_url =
|
||||
sdl2_config->GetString("WebService", "web_api_url", "https://api.citra-emu.org");
|
||||
NetSettings::values.citra_username = sdl2_config->GetString("WebService", "citra_username", "");
|
||||
|
@ -334,7 +334,7 @@ gdbstub_port=24689
|
||||
|
||||
[WebService]
|
||||
# Whether or not to enable telemetry
|
||||
# 0: No, 1 (default): Yes
|
||||
# 0 (default): No, 1: Yes
|
||||
enable_telemetry =
|
||||
# URL for Web API
|
||||
web_api_url = https://api.citra-emu.org
|
||||
|
@ -313,7 +313,7 @@ void Config::ReadValues() {
|
||||
|
||||
// Web Service
|
||||
NetSettings::values.enable_telemetry =
|
||||
sdl2_config->GetBoolean("WebService", "enable_telemetry", true);
|
||||
sdl2_config->GetBoolean("WebService", "enable_telemetry", false);
|
||||
NetSettings::values.web_api_url =
|
||||
sdl2_config->GetString("WebService", "web_api_url", "https://api.citra-emu.org");
|
||||
NetSettings::values.citra_username = sdl2_config->GetString("WebService", "citra_username", "");
|
||||
|
@ -349,7 +349,7 @@ renderer_debug =
|
||||
|
||||
[WebService]
|
||||
# Whether or not to enable telemetry
|
||||
# 0: No, 1 (default): Yes
|
||||
# 0 (default): No, 1: Yes
|
||||
enable_telemetry =
|
||||
# URL for Web API
|
||||
web_api_url = https://api.citra-emu.org
|
||||
|
@ -803,7 +803,7 @@ void Config::ReadWebServiceValues() {
|
||||
qt_config->beginGroup(QStringLiteral("WebService"));
|
||||
|
||||
NetSettings::values.enable_telemetry =
|
||||
ReadSetting(QStringLiteral("enable_telemetry"), true).toBool();
|
||||
ReadSetting(QStringLiteral("enable_telemetry"), false).toBool();
|
||||
NetSettings::values.web_api_url =
|
||||
ReadSetting(QStringLiteral("web_api_url"), QStringLiteral("https://api.citra-emu.org"))
|
||||
.toString()
|
||||
|
@ -145,8 +145,8 @@ void GMainWindow::ShowTelemetryCallout() {
|
||||
tr("<a href='https://citra-emu.org/entry/telemetry-and-why-thats-a-good-thing/'>Anonymous "
|
||||
"data is collected</a> to help improve Citra. "
|
||||
"<br/><br/>Would you like to share your usage data with us?");
|
||||
if (QMessageBox::question(this, tr("Telemetry"), telemetry_message) != QMessageBox::Yes) {
|
||||
NetSettings::values.enable_telemetry = false;
|
||||
if (QMessageBox::question(this, tr("Telemetry"), telemetry_message) == QMessageBox::Yes) {
|
||||
NetSettings::values.enable_telemetry = true;
|
||||
Settings::Apply();
|
||||
}
|
||||
}
|
||||
|
@ -21,6 +21,8 @@ std::optional<std::vector<u8>> Download(const std::string& path) {
|
||||
httplib::Request request{
|
||||
.method = "GET",
|
||||
.path = path,
|
||||
// Needed when httplib is included on android
|
||||
.matches = httplib::Match(),
|
||||
};
|
||||
|
||||
client->set_follow_location(true);
|
||||
|
Loading…
Reference in New Issue
Block a user