diff options
Diffstat (limited to 'app/src/main')
-rw-r--r-- | app/src/main/java/github/daneren2005/dsub/adapter/BookmarkAdapter.java | 17 | ||||
-rw-r--r-- | app/src/main/res/values/strings.xml | 8 |
2 files changed, 19 insertions, 6 deletions
diff --git a/app/src/main/java/github/daneren2005/dsub/adapter/BookmarkAdapter.java b/app/src/main/java/github/daneren2005/dsub/adapter/BookmarkAdapter.java index 8335966d..8e960de4 100644 --- a/app/src/main/java/github/daneren2005/dsub/adapter/BookmarkAdapter.java +++ b/app/src/main/java/github/daneren2005/dsub/adapter/BookmarkAdapter.java @@ -18,6 +18,9 @@ package github.daneren2005.dsub.adapter; import android.content.Context; import java.util.List; + +import android.view.Menu; +import android.view.MenuInflater; import android.view.ViewGroup; import android.widget.TextView; @@ -34,6 +37,7 @@ public class BookmarkAdapter extends SectionAdapter<MusicDirectory.Entry> { public BookmarkAdapter(Context activity, List<MusicDirectory.Entry> bookmarks, OnItemClickedListener listener) { super(activity, bookmarks); this.onItemClickedListener = listener; + checkable = true; } @Override @@ -46,7 +50,7 @@ public class BookmarkAdapter extends SectionAdapter<MusicDirectory.Entry> { SongView songView = (SongView) holder.getUpdateView(); Bookmark bookmark = item.getBookmark(); - songView.setObject(item, false); + songView.setObject(item, true); // Add current position to duration TextView durationTextView = (TextView) songView.findViewById(R.id.song_duration); @@ -58,4 +62,15 @@ public class BookmarkAdapter extends SectionAdapter<MusicDirectory.Entry> { public int getItemViewType(MusicDirectory.Entry item) { return EntryGridAdapter.VIEW_TYPE_SONG; } + + @Override + public void onCreateActionModeMenu(Menu menu, MenuInflater menuInflater) { + if(Util.isOffline(context)) { + menuInflater.inflate(R.menu.multiselect_media_offline, menu); + } else { + menuInflater.inflate(R.menu.multiselect_media, menu); + } + + menu.removeItem(R.id.menu_remove_playlist); + } } diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index b783f0b9..ec6c45b4 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -242,11 +242,6 @@ <string name="bookmark.deleted">Deleted the bookmark for \"%s\"</string> <string name="bookmark.deleted_error">Failed to delete the bookmark for \"%s\"</string> <string name="bookmark.details_title">Bookmark Details</string> - <string name="bookmark.details">Song: %1$s - \nPosition: %2$s - \nCreated: %3$s - \nLast Updated: %4$s - \nComment: %5$s</string> <string name="bookmark.resume_title">Resume playing?</string> <string name="bookmark.resume">Resume playing \'%1$s\' from %2$s</string> <string name="bookmark.action_resume">Resume</string> @@ -620,6 +615,9 @@ <string name="details.used_space">Used Space</string> <string name="details.available_space">Available Space</string> <string name="details.of">%1$s of %2$s</string> + <string name="details.song">Song</string> + <string name="details.position">Position</string> + <string name="details.updated">Updated</string> <plurals name="select_album_n_songs"> <item quantity="zero">No songs</item> |