diff options
Diffstat (limited to 'src/github/daneren2005')
-rw-r--r-- | src/github/daneren2005/dsub/view/SeekBarPreference.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/github/daneren2005/dsub/view/SeekBarPreference.java b/src/github/daneren2005/dsub/view/SeekBarPreference.java index e96d76f8..a22d049b 100644 --- a/src/github/daneren2005/dsub/view/SeekBarPreference.java +++ b/src/github/daneren2005/dsub/view/SeekBarPreference.java @@ -116,7 +116,11 @@ public class SeekBarPreference extends DialogPreference implements SeekBar.OnSee SeekBar seekBar = (SeekBar)view.findViewById(R.id.seek_bar);
seekBar.setMax(mMax - mMin);
- seekBar.setProgress(Integer.parseInt(mValue));
+ try {
+ seekBar.setProgress(Integer.parseInt(mValue));
+ } catch(Exception e) {
+ seekBar.setProgress(0);
+ }
seekBar.setOnSeekBarChangeListener(this);
return view;
|