Skip to content

Commit

Permalink
[builtins] adds ToggleDirtyRegions builtin
Browse files Browse the repository at this point in the history
  • Loading branch information
mkortstiege committed Aug 31, 2015
1 parent ef3ea04 commit cf7d201
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
5 changes: 5 additions & 0 deletions xbmc/interfaces/Builtins.cpp
Expand Up @@ -237,6 +237,7 @@ const BUILT_IN commands[] = {
#endif
{ "VideoLibrary.Search", false, "Brings up a search dialog which will search the library" },
{ "ToggleDebug", false, "Enables/disables debug mode" },
{ "ToggleDirtyRegions", false, "Enables/disables dirty-region visualization" },
{ "StartPVRManager", false, "(Re)Starts the PVR manager (Deprecated)" },
{ "StopPVRManager", false, "Stops the PVR manager (Deprecated)" },
{ "PVR.StartManager", false, "(Re)Starts the PVR manager" },
Expand Down Expand Up @@ -1856,6 +1857,10 @@ int CBuiltins::Execute(const std::string& execString)
CSettings::GetInstance().SetBool(CSettings::SETTING_DEBUG_SHOWLOGINFO, !debug);
g_advancedSettings.SetDebugMode(!debug);
}
else if (execute == "toggledirtyregions")
{
g_advancedSettings.ToggleDirtyRegions();
}
//TODO deprecated. To be replaced by pvr.startmanager
else if (execute == "startpvrmanager")
{
Expand Down
3 changes: 3 additions & 0 deletions xbmc/settings/AdvancedSettings.h
Expand Up @@ -384,6 +384,9 @@ class CAdvancedSettings : public ISettingCallback, public ISettingsHandler

void SetDebugMode(bool debug);

//! \brief Toggles dirty-region visualization
void ToggleDirtyRegions() { m_guiVisualizeDirtyRegions = !m_guiVisualizeDirtyRegions; };

// runtime settings which cannot be set from advancedsettings.xml
std::string m_pictureExtensions;
std::string m_videoExtensions;
Expand Down

0 comments on commit cf7d201

Please sign in to comment.