Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
CGUIControlBaseSetting Class Referenceabstract

#include <GUIControlSettings.h>

Inheritance diagram for CGUIControlBaseSetting:
ILocalizer CGUIControlButtonSetting CGUIControlColorButtonSetting CGUIControlEditSetting CGUIControlGroupTitleSetting CGUIControlLabelSetting CGUIControlListColorSetting CGUIControlListSetting CGUIControlRadioButtonSetting CGUIControlRangeSetting CGUIControlSeparatorSetting CGUIControlSliderSetting CGUIControlSpinExSetting

Public Member Functions

 CGUIControlBaseSetting (int id, std::shared_ptr< CSetting > pSetting, ILocalizer *localizer)
 
 ~CGUIControlBaseSetting () override=default
 
int GetID () const
 
std::shared_ptr< CSettingGetSetting ()
 
void SetDelayed ()
 Specifies that this setting should update after a delay Useful for settings that have options to navigate through and may take a while, or require additional input to update once the final setting is chosen. Settings default to updating instantly.
 
bool IsDelayed () const
 Returns whether this setting should have delayed update.
 
bool IsEnabled () const
 Returns whether this setting is enabled or disabled This state is independent of the real enabled state of a setting control but represents the enabled state of the setting itself based on specific conditions.
 
bool IsValid () const
 Returns whether the setting's value is valid or not.
 
void SetValid (bool valid)
 
virtual CGUIControlGetControl ()
 
virtual bool OnClick ()
 
void UpdateFromControl ()
 
void UpdateFromSetting (bool updateDisplayOnly=false)
 
virtual void Clear ()=0
 Clears the attached control.
 

Protected Member Functions

std::string Localize (std::uint32_t code) const override
 
virtual void Update (bool fromControl, bool updateDisplayOnly)
 
- Protected Member Functions inherited from ILocalizer
 ILocalizer ()=default
 
virtual ~ILocalizer ()=default
 

Protected Attributes

int m_id
 
std::shared_ptr< CSettingm_pSetting
 
ILocalizerm_localizer
 
bool m_delayed = false
 
bool m_valid = true
 

Constructor & Destructor Documentation

◆ CGUIControlBaseSetting()

CGUIControlBaseSetting::CGUIControlBaseSetting ( int id,
std::shared_ptr< CSetting > pSetting,
ILocalizer * localizer )

◆ ~CGUIControlBaseSetting()

CGUIControlBaseSetting::~CGUIControlBaseSetting ( )
overridedefault

Member Function Documentation

◆ Clear()

◆ GetControl()

◆ GetID()

int CGUIControlBaseSetting::GetID ( ) const
inline

◆ GetSetting()

std::shared_ptr< CSetting > CGUIControlBaseSetting::GetSetting ( )
inline

◆ IsDelayed()

bool CGUIControlBaseSetting::IsDelayed ( ) const
inline

Returns whether this setting should have delayed update.

Returns
true if the setting's update should be delayed
See also
SetDelayed()

◆ IsEnabled()

bool CGUIControlBaseSetting::IsEnabled ( ) const

Returns whether this setting is enabled or disabled This state is independent of the real enabled state of a setting control but represents the enabled state of the setting itself based on specific conditions.

Returns
true if the setting is enabled otherwise false
See also
SetEnabled()

◆ IsValid()

bool CGUIControlBaseSetting::IsValid ( ) const
inline

Returns whether the setting's value is valid or not.

◆ Localize()

std::string CGUIControlBaseSetting::Localize ( std::uint32_t code) const
overrideprotectedvirtual

Implements ILocalizer.

◆ OnClick()

◆ SetDelayed()

void CGUIControlBaseSetting::SetDelayed ( )
inline

Specifies that this setting should update after a delay Useful for settings that have options to navigate through and may take a while, or require additional input to update once the final setting is chosen. Settings default to updating instantly.

See also
IsDelayed()

◆ SetValid()

void CGUIControlBaseSetting::SetValid ( bool valid)
inline

◆ Update()

◆ UpdateFromControl()

void CGUIControlBaseSetting::UpdateFromControl ( )

◆ UpdateFromSetting()

void CGUIControlBaseSetting::UpdateFromSetting ( bool updateDisplayOnly = false)

Member Data Documentation

◆ m_delayed

bool CGUIControlBaseSetting::m_delayed = false
protected

◆ m_id

int CGUIControlBaseSetting::m_id
protected

◆ m_localizer

ILocalizer* CGUIControlBaseSetting::m_localizer
protected

◆ m_pSetting

std::shared_ptr<CSetting> CGUIControlBaseSetting::m_pSetting
protected

◆ m_valid

bool CGUIControlBaseSetting::m_valid = true
protected

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