Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
ADDON::CAddonSystemSettings Class Reference

#include <AddonSystemSettings.h>

Inheritance diagram for ADDON::CAddonSystemSettings:
ISettingCallback

Public Member Functions

void OnSettingAction (const std::shared_ptr< const CSetting > &setting) override
 The given setting has been activated.
 
void OnSettingChanged (const std::shared_ptr< const CSetting > &setting) override
 The value of the given setting has changed.
 
bool GetActive (AddonType type, AddonPtr &addon)
 
bool SetActive (AddonType type, const std::string &addonID)
 
bool IsActive (const IAddon &addon)
 
int GetAddonAutoUpdateMode () const
 
AddonRepoUpdateMode GetAddonRepoUpdateMode () const
 
bool UnsetActive (const AddonInfoPtr &addon)
 
- Public Member Functions inherited from ISettingCallback
virtual ~ISettingCallback ()=default
 
virtual bool OnSettingChanging (const std::shared_ptr< const CSetting > &setting)
 The value of the given setting is being changed.
 
virtual bool OnSettingUpdate (const std::shared_ptr< CSetting > &setting, const char *oldSettingId, const TiXmlNode *oldSettingNode)
 The given setting needs to be updated.
 
virtual void OnSettingPropertyChanged (const std::shared_ptr< const CSetting > &setting, const char *propertyName)
 The given property of the given setting has changed.
 

Static Public Member Functions

static CAddonSystemSettingsGetInstance ()
 

Member Function Documentation

◆ GetActive()

bool ADDON::CAddonSystemSettings::GetActive ( AddonType type,
AddonPtr & addon )

◆ GetAddonAutoUpdateMode()

int ADDON::CAddonSystemSettings::GetAddonAutoUpdateMode ( ) const

Gets Kodi addon auto update mode

Returns
the autoupdate mode value

◆ GetAddonRepoUpdateMode()

AddonRepoUpdateMode ADDON::CAddonSystemSettings::GetAddonRepoUpdateMode ( ) const

Gets Kodi preferred addon repository update mode

Returns
the preferred mode value

◆ GetInstance()

CAddonSystemSettings & ADDON::CAddonSystemSettings::GetInstance ( )
static

◆ IsActive()

bool ADDON::CAddonSystemSettings::IsActive ( const IAddon & addon)

◆ OnSettingAction()

void ADDON::CAddonSystemSettings::OnSettingAction ( const std::shared_ptr< const CSetting > & setting)
overridevirtual

The given setting has been activated.

This callback is triggered whenever the given setting has been activated. This callback is only fired for CSettingAction settings.

Parameters
settingThe setting which has been activated.

Reimplemented from ISettingCallback.

◆ OnSettingChanged()

void ADDON::CAddonSystemSettings::OnSettingChanged ( const std::shared_ptr< const CSetting > & setting)
overridevirtual

The value of the given setting has changed.

This callback is triggered whenever the value of a setting has been successfully changed (i.e. none of the OnSettingChanging() handlers) has reverted the change.

Parameters
settingThe setting whose value has been changed

Reimplemented from ISettingCallback.

◆ SetActive()

bool ADDON::CAddonSystemSettings::SetActive ( AddonType type,
const std::string & addonID )

◆ UnsetActive()

bool ADDON::CAddonSystemSettings::UnsetActive ( const AddonInfoPtr & addon)

Attempt to unset addon as active. Returns true if addon is no longer active, false if it could not be unset (e.g. if the addon is the default)


The documentation for this class was generated from the following files: