Commit 99cf7dde authored by Geoffrey Métais's avatar Geoffrey Métais
Browse files

Unregister preferences listener on stop

parent 9a831aba
......@@ -31,7 +31,6 @@ import android.support.v7.preference.TwoStatePreference;
import org.videolan.libvlc.util.AndroidUtil;
import org.videolan.libvlc.util.HWDecoderUtil;
import org.videolan.vlc.PlaybackService;
import org.videolan.vlc.R;
import org.videolan.vlc.util.Constants;
import org.videolan.vlc.util.VLCInstance;
......@@ -73,6 +72,12 @@ public class PreferencesAudio extends BasePreferenceFragment implements SharedPr
getPreferenceScreen().getSharedPreferences().registerOnSharedPreferenceChangeListener(this);
}
@Override
public void onStop() {
super.onStop();
getPreferenceScreen().getSharedPreferences().unregisterOnSharedPreferenceChangeListener(this);
}
@Override
public boolean onPreferenceTreeClick(Preference preference) {
if (preference.getKey() == null) return false;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment