Commit e5ac2253 authored by Aloshi's avatar Aloshi

Ctrl-R now also reloads the system view when in debug mode.

parent 6cf6e62b
......@@ -112,7 +112,7 @@ Or, you can create your own elements by adding `extra="true"` (as is done in the
Advanced Features
=================
It is recommended that if you are writing a theme you launch EmulationStation with the `--debug` and `--windowed` switches. This way you can read error messages without having to check the log file. You can also reload the current gamelist view with `Ctrl-R` if `--debug` is specified.
It is recommended that if you are writing a theme you launch EmulationStation with the `--debug` and `--windowed` switches. This way you can read error messages without having to check the log file. You can also reload the current gamelist view and system view with `Ctrl-R` if `--debug` is specified.
### The `<include>` tag
......
......@@ -6,6 +6,7 @@
#include "ViewController.h"
#include "../animations/LambdaAnimation.h"
#include "../SystemData.h"
#include "../Settings.h"
#include "../Util.h"
#define SELECTED_SCALE 1.5f
......@@ -91,6 +92,17 @@ bool SystemView::input(InputConfig* config, Input input)
{
if(input.value != 0)
{
if(config->getDeviceId() == DEVICE_KEYBOARD && input.value && input.id == SDLK_r && SDL_GetModState() & KMOD_LCTRL && Settings::getInstance()->getBool("Debug"))
{
LOG(LogInfo) << " Reloading SystemList view";
// reload themes
for(auto it = mEntries.begin(); it != mEntries.end(); it++)
it->object->loadTheme();
populate();
return true;
}
if(config->isMappedTo("left", input))
{
listInput(-1);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment