Skip to content
Browse files

fix saving of option=int slider add-on settings

  • Loading branch information...
1 parent fbc641f commit 022591042f37eb8bb531ef731b883cdf7b36427a Jonathan Marshall committed
Showing with 7 additions and 1 deletion.
  1. +7 −1 xbmc/addons/GUIDialogAddonSettings.cpp
View
8 xbmc/addons/GUIDialogAddonSettings.cpp
@@ -523,7 +523,13 @@ void CGUIDialogAddonSettings::UpdateFromControls()
value.Format("%i", ((CGUISpinControlEx*) control)->GetValue());
break;
case CGUIControl::GUICONTROL_SETTINGS_SLIDER:
- value.Format("%f", ((CGUISettingsSliderControl *)control)->GetFloatValue());
+ {
+ CStdString option = setting->Attribute("option");
+ if (option.size() == 0 || option.CompareNoCase("float") == 0)
+ value.Format("%f", ((CGUISettingsSliderControl *)control)->GetFloatValue());
+ else
+ value.Format("%i", ((CGUISettingsSliderControl *)control)->GetIntValue());
+ }
break;
default:
break;

0 comments on commit 0225910

Please sign in to comment.
Something went wrong with that request. Please try again.