aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2015-02-21 20:34:11 -0800
committerScott Jackson <daneren2005@gmail.com>2015-02-21 20:34:11 -0800
commit43cbeb065de81f18b63331b8e98f325e79fda3ef (patch)
tree8a2e3390b1f42731b27a6fa6bb743dc5d8e7bc1d
parentac02a0ffab53d0de4c3e5b48fbbdc5643fbbc79d (diff)
downloaddsub-43cbeb065de81f18b63331b8e98f325e79fda3ef.tar.gz
dsub-43cbeb065de81f18b63331b8e98f325e79fda3ef.tar.bz2
dsub-43cbeb065de81f18b63331b8e98f325e79fda3ef.zip
Add error handler for toggling EQ
-rw-r--r--src/github/daneren2005/dsub/fragments/EqualizerFragment.java8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/github/daneren2005/dsub/fragments/EqualizerFragment.java b/src/github/daneren2005/dsub/fragments/EqualizerFragment.java
index de6b5e0a..8cc245bd 100644
--- a/src/github/daneren2005/dsub/fragments/EqualizerFragment.java
+++ b/src/github/daneren2005/dsub/fragments/EqualizerFragment.java
@@ -93,7 +93,13 @@ public class EqualizerFragment extends SubsonicFragment {
enabledCheckBox.setOnCheckedChangeListener(new CompoundButton.OnCheckedChangeListener() {
@Override
public void onCheckedChanged(CompoundButton compoundButton, boolean b) {
- setEqualizerEnabled(b);
+ try {
+ setEqualizerEnabled(b);
+ } catch(Exception e) {
+ Log.e(TAG, "Failed to set EQ enabled", e);
+ Util.toast(context, "Failed to set EQ enabled");
+ context.onBackPressed();
+ }
}
});