diff options
-rw-r--r-- | system/settings/settings.xml | 4 | ||||
-rw-r--r-- | xbmc/settings/SettingControl.cpp | 2 | ||||
-rw-r--r-- | xbmc/settings/SettingControl.h | 3 | ||||
-rw-r--r-- | xbmc/settings/windows/GUIControlSettings.cpp | 5 |
4 files changed, 9 insertions, 5 deletions
diff --git a/system/settings/settings.xml b/system/settings/settings.xml index d25dd72180..a6bed23f0b 100644 --- a/system/settings/settings.xml +++ b/system/settings/settings.xml @@ -101,7 +101,7 @@ <dependencies> <dependency type="enable" setting="lookandfeel.enablerssfeeds">true</dependency> </dependencies> - <control type="button" format="action" /> + <control type="button" format="action" attributes="hide_value" /> </setting> </group> </category> @@ -2359,7 +2359,7 @@ <setting id="masterlock.lockcode" type="string" label="20100" help="36396"> <level>2</level> <default>-</default> - <control type="button" format="action" /> + <control type="button" format="action" attributes="hide_value"/> </setting> <setting id="masterlock.startuplock" type="boolean" label="20076" help="36397"> <level>2</level> diff --git a/xbmc/settings/SettingControl.cpp b/xbmc/settings/SettingControl.cpp index 833c255c7c..f70699cb59 100644 --- a/xbmc/settings/SettingControl.cpp +++ b/xbmc/settings/SettingControl.cpp @@ -126,6 +126,8 @@ bool CSettingControl::setAttributes(const std::string &strAttributes) controlAttributes |= (int)SettingControlAttributeHidden; else if (StringUtils::EqualsNoCase(*attribute, "new")) controlAttributes |= (int)SettingControlAttributeVerifyNew; + else if (StringUtils::EqualsNoCase(*attribute, "hide_value")) + controlAttributes |= (int)SettingControlAttributeHideValue; else return false; } diff --git a/xbmc/settings/SettingControl.h b/xbmc/settings/SettingControl.h index 35c1998bf4..37db6a7bae 100644 --- a/xbmc/settings/SettingControl.h +++ b/xbmc/settings/SettingControl.h @@ -48,7 +48,8 @@ typedef enum { typedef enum { SettingControlAttributeNone = 0x0, SettingControlAttributeHidden = 0x1, - SettingControlAttributeVerifyNew = 0x2 + SettingControlAttributeVerifyNew = 0x2, + SettingControlAttributeHideValue = 0x4 } SettingControlAttribute; class CSettingControl diff --git a/xbmc/settings/windows/GUIControlSettings.cpp b/xbmc/settings/windows/GUIControlSettings.cpp index f9dbeadbe4..eee1f92e45 100644 --- a/xbmc/settings/windows/GUIControlSettings.cpp +++ b/xbmc/settings/windows/GUIControlSettings.cpp @@ -470,7 +470,8 @@ void CGUIControlButtonSetting::Update() CGUIControlBaseSetting::Update(); - if (m_pSetting->GetType() == SettingTypeString) + if (m_pSetting->GetType() == SettingTypeString && + !(m_pSetting->GetControl().GetAttributes() & SettingControlAttributeHideValue)) { std::string strText = ((CSettingString *)m_pSetting)->GetValue(); switch (m_pSetting->GetControl().GetFormat()) @@ -494,7 +495,7 @@ void CGUIControlButtonSetting::Update() } default: - return; + break; } m_pButton->SetLabel2(strText); |