fixed naming and formatting issues

This commit is contained in:
Grady Clark 2020-04-21 01:03:42 -05:00
parent db335d5cec
commit 776ddddc83
No known key found for this signature in database
GPG Key ID: F7AFAC4616D2FF5E
3 changed files with 10 additions and 10 deletions

View File

@ -259,8 +259,8 @@ public class LocalPlaylistFragment extends BaseLocalListFragment<List<PlaylistSt
@Override @Override
public void onCreateOptionsMenu(final Menu menu, final MenuInflater inflater) { public void onCreateOptionsMenu(final Menu menu, final MenuInflater inflater) {
if (DEBUG) { if (DEBUG) {
Log.d(TAG, "onCreateOptionsMenu() called with: menu = [" + menu Log.d(TAG, "onCreateOptionsMenu() called with: "
+ "], inflater = [" + inflater + "]"); + "menu = [" + menu + "], inflater = [" + inflater + "]");
} }
super.onCreateOptionsMenu(menu, inflater); super.onCreateOptionsMenu(menu, inflater);
inflater.inflate(R.menu.menu_local_playlist, menu); inflater.inflate(R.menu.menu_local_playlist, menu);
@ -361,7 +361,7 @@ public class LocalPlaylistFragment extends BaseLocalListFragment<List<PlaylistSt
@Override @Override
public boolean onOptionsItemSelected(final MenuItem item) { public boolean onOptionsItemSelected(final MenuItem item) {
switch (item.getItemId()) { switch (item.getItemId()) {
case R.id.menu_item_removeWatched: case R.id.menu_item_remove_watched:
new AlertDialog.Builder(getActivity()) new AlertDialog.Builder(getActivity())
.setMessage(R.string.remove_watched_popup_warning) .setMessage(R.string.remove_watched_popup_warning)
.setTitle(R.string.remove_watched_popup_title) .setTitle(R.string.remove_watched_popup_title)
@ -391,16 +391,16 @@ public class LocalPlaylistFragment extends BaseLocalListFragment<List<PlaylistSt
removeWatchedDisposable = playlistManager.getPlaylistStreams(playlistId) removeWatchedDisposable = playlistManager.getPlaylistStreams(playlistId)
.subscribeOn(Schedulers.io()) .subscribeOn(Schedulers.io())
.map((List<PlaylistStreamEntry> playlist) -> { .map((List<PlaylistStreamEntry> playlist) -> {
//Playlist data // Playlist data
Iterator<PlaylistStreamEntry> playlistIter = playlist.iterator(); Iterator<PlaylistStreamEntry> playlistIter = playlist.iterator();
//History data // History data
HistoryRecordManager recordManager = new HistoryRecordManager(getContext()); HistoryRecordManager recordManager = new HistoryRecordManager(getContext());
Iterator<StreamHistoryEntry> historyIter = recordManager Iterator<StreamHistoryEntry> historyIter = recordManager
.getStreamHistorySortedById().blockingFirst().iterator(); .getStreamHistorySortedById().blockingFirst().iterator();
Iterator<StreamStateEntity> streamStatesIter = null; Iterator<StreamStateEntity> streamStatesIter = null;
//Remove Watched, Functionality data // Remove Watched, Functionality data
List<PlaylistStreamEntry> notWatchedItems = new ArrayList<>(); List<PlaylistStreamEntry> notWatchedItems = new ArrayList<>();
boolean thumbnailVideoRemoved = false; boolean thumbnailVideoRemoved = false;
@ -471,8 +471,8 @@ public class LocalPlaylistFragment extends BaseLocalListFragment<List<PlaylistSt
hideLoading(); hideLoading();
//If this is not done, 'removeWatchedDisposable', will never be disposed of. // If this is not done, 'removeWatchedDisposable', will never be disposed of.
//Why: Because using the 'removePartiallyWatched' in this functions parms, // Why: Because using the 'removePartiallyWatched' in this functions parms,
// prevents it from disposing. Exact reason for this behavior is unknown // prevents it from disposing. Exact reason for this behavior is unknown
removeWatchedDisposable.dispose(); removeWatchedDisposable.dispose();
removeWatchedDisposable = null; removeWatchedDisposable = null;

View File

@ -4,7 +4,7 @@
xmlns:tools="http://schemas.android.com/tools"> xmlns:tools="http://schemas.android.com/tools">
<item <item
android:id="@+id/menu_item_removeWatched" android:id="@+id/menu_item_remove_watched"
android:title="@string/remove_watched" android:title="@string/remove_watched"
app:showAsAction="never"/> app:showAsAction="never"/>
</menu> </menu>

View File

@ -603,7 +603,7 @@
<string name="systems_language">System default</string> <string name="systems_language">System default</string>
<string name="remove_watched">Remove watched</string> <string name="remove_watched">Remove watched</string>
<string name="remove_watched_popup_title">Remove watched videos?</string> <string name="remove_watched_popup_title">Remove watched videos?</string>
<string name="remove_watched_popup_warning">"Videos that have been watched\nbefore and after being added to the playlist will be removed.\nAre you sure? This cannot be undone!</string> <string name="remove_watched_popup_warning">Videos that have been watched before and after being added to the playlist will be removed.\nAre you sure? This cannot be undone!</string>
<string name="remove_watched_popup_yes_and_partially_watched_videos">Yes, and partially watched videos</string> <string name="remove_watched_popup_yes_and_partially_watched_videos">Yes, and partially watched videos</string>
<string name="new_seek_duration_toast">Due to ExoPlayer constraints the seek duration was set to %d seconds</string> <string name="new_seek_duration_toast">Due to ExoPlayer constraints the seek duration was set to %d seconds</string>
<!-- Time duration plurals --> <!-- Time duration plurals -->