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

This commit is contained in:
Aloshi 2014-05-24 11:09:45 -05:00
parent 6cf6e62b85
commit e5ac225362
2 changed files with 13 additions and 1 deletions

View file

@ -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

View file

@ -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);