Logging: Add customizable logging backends and fmtlib based macros

* Change the logging backend to support multiple sinks through the
Backend Interface
* Add a new set of logging macros to use fmtlib instead.
* Qt: Compile as GUI application on windows to make the console hidden by
default. Add filter configuration and a button to open log location.
* SDL: Migrate to the new logging macros
This commit is contained in:
James Rowe 2018-02-19 17:51:27 -07:00 committed by Daniel Lim Wee Soong
parent 3cda637cb1
commit 0daac3020e
25 changed files with 527 additions and 140 deletions

View file

@ -24,10 +24,18 @@ const std::array<int, Settings::NativeButton::NumButtons> Config::default_button
const std::array<std::array<int, 5>, Settings::NativeAnalog::NumAnalogs> Config::default_analogs{{
{
Qt::Key_Up, Qt::Key_Down, Qt::Key_Left, Qt::Key_Right, Qt::Key_D,
Qt::Key_Up,
Qt::Key_Down,
Qt::Key_Left,
Qt::Key_Right,
Qt::Key_D,
},
{
Qt::Key_I, Qt::Key_K, Qt::Key_J, Qt::Key_L, Qt::Key_D,
Qt::Key_I,
Qt::Key_K,
Qt::Key_J,
Qt::Key_L,
Qt::Key_D,
},
}};
@ -216,6 +224,7 @@ void Config::ReadValues() {
UISettings::values.confirm_before_closing = qt_config->value("confirmClose", true).toBool();
UISettings::values.first_start = qt_config->value("firstStart", true).toBool();
UISettings::values.callout_flags = qt_config->value("calloutFlags", 0).toUInt();
UISettings::values.show_console = qt_config->value("showConsole", false).toBool();
qt_config->endGroup();
}
@ -357,6 +366,7 @@ void Config::SaveValues() {
qt_config->setValue("confirmClose", UISettings::values.confirm_before_closing);
qt_config->setValue("firstStart", UISettings::values.first_start);
qt_config->setValue("calloutFlags", UISettings::values.callout_flags);
qt_config->setValue("showConsole", UISettings::values.show_console);
qt_config->endGroup();
}