Merge pull request #2987 from ByteHamster/audio-settings-dialog

Hiding settings that ExoPlayer does not yet support
This commit is contained in:
H. Lehmann 2019-01-15 11:21:54 +01:00 committed by GitHub
commit 6d50be18db
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 1 deletions

View File

@ -534,11 +534,16 @@ public abstract class MediaplayerActivity extends CastEnabledActivity implements
stereoToMono.setText(stereoToMono.getText() + " [" + sonicOnly + "]");
}
if (UserPreferences.useExoplayer()) {
barRightVolume.setEnabled(false);
}
final CheckBox skipSilence = (CheckBox) dialog.findViewById(R.id.skipSilence);
skipSilence.setChecked(UserPreferences.isSkipSilence());
if (!UserPreferences.useExoplayer()) {
skipSilence.setEnabled(false);
skipSilence.setText(skipSilence.getText() + "[ ExoPlayer only ]");
String exoplayerOnly = getString(R.string.exoplayer_only);
skipSilence.setText(skipSilence.getText() + " [" + exoplayerOnly + "]");
}
skipSilence.setOnCheckedChangeListener((buttonView, isChecked) -> {
UserPreferences.setSkipSilence(isChecked);

View File

@ -692,6 +692,7 @@
<string name="audio_effects">Audio Effects</string>
<string name="stereo_to_mono">Downmix: Stereo to mono</string>
<string name="sonic_only">Sonic only</string>
<string name="exoplayer_only">ExoPlayer only</string>
<!-- proxy settings -->
<string name="proxy_type_label">Type</string>