Merge pull request #5469 from ByteHamster/compact-notification-button-default

Use ff/rew as default notification buttons
This commit is contained in:
ByteHamster 2021-10-16 07:50:58 +02:00 committed by GitHub
commit b860ee33d0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions

View File

@ -126,8 +126,9 @@ public class PreferencesTest {
clickPreference(R.string.user_interface_label); clickPreference(R.string.user_interface_label);
String[] buttons = res.getStringArray(R.array.compact_notification_buttons_options); String[] buttons = res.getStringArray(R.array.compact_notification_buttons_options);
clickPreference(R.string.pref_compact_notification_buttons_title); clickPreference(R.string.pref_compact_notification_buttons_title);
// First uncheck checkbox // First uncheck checkboxes
onView(withText(buttons[2])).perform(click()); onView(withText(buttons[0])).perform(click());
onView(withText(buttons[1])).perform(click());
// Now try to check all checkboxes // Now try to check all checkboxes
onView(withText(buttons[0])).perform(click()); onView(withText(buttons[0])).perform(click());

View File

@ -207,7 +207,7 @@ public class UserPreferences {
public static List<Integer> getCompactNotificationButtons() { public static List<Integer> getCompactNotificationButtons() {
String[] buttons = TextUtils.split( String[] buttons = TextUtils.split(
prefs.getString(PREF_COMPACT_NOTIFICATION_BUTTONS, prefs.getString(PREF_COMPACT_NOTIFICATION_BUTTONS,
String.valueOf(NOTIFICATION_BUTTON_SKIP)), NOTIFICATION_BUTTON_REWIND + "," + NOTIFICATION_BUTTON_FAST_FORWARD),
","); ",");
List<Integer> notificationButtons = new ArrayList<>(); List<Integer> notificationButtons = new ArrayList<>();
for (String button : buttons) { for (String button : buttons) {