Skip to content
Snippets Groups Projects

MediaCategoryViewController: Last Played Playlist Media Indicator

Merged Mohamed Sliem requested to merge Sliem/vlc-ios:LastPlayedPlaylistIndicator into master

The following feature was requested in #1760 (closed)

I have added an indicator to the MediaCategoryViewController for the last played playlist and its last played media. it is immediately updated based on the playback state. When the playback is active, it is hidden, and when the playback is stopped, it is shown.

The indicator can detect the playlist and its media in the following scenarios:

  • When playing a single media from a playlist.
  • When playing an entire playlist.
  • When switching from playing an entire playlist to a single media from the playlist, and vice versa.

All of these cases are detected using the tap select action and long press gestures actions (play, play next in queue, and append to queue) when the queue is empty.

For MovieCollectionViewCell, added a label called groupLastPlayed for indicating the playlist in Grid mode, and for a single media inside the playlist Grid mode is not an option.

Video PlaylistMediaIndicator
Edited by Mohamed Sliem

Merge request reports

Merge request pipeline #567226 passed

Merge request pipeline passed for c8c81a5c

Approved by

Merged by Felix Paul KühneFelix Paul Kühne 2 months ago (Feb 16, 2025 6:59pm UTC)

Merge details

  • Changes merged into master with c8c81a5c.
  • Deleted the source branch.
  • Auto-merge enabled

Pipeline #567228 passed

Pipeline passed for c8c81a5c on master

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Diogo Simao Marques
  • Mohamed Sliem added 26 commits

    added 26 commits

    • 3d943c0c...129c8b22 - 2 commits from branch videolan:master
    • 129c8b22...1c9ce88b - 14 earlier commits
    • cf07dc73 - LastPlayedPlaylistModel: Added Last Played Media Model
    • 7ab02876 - MediaCategoryViewController: Saving last played media addition
    • d40031ac - Added LastPlaylistPlayedMedia Key
    • 6f4b0ac2 - VLCPlaybackService: Update PlaybackWillStop Observer user info
    • ccda2ade - MediaCategoryViewController: Captured last played media
    • d63be725 - MediaCategoryViewController: Check the last played media in a given
    • 0aaaacd2 - MediaCateogoryViewController: Added isLastMedia to check condition
    • 09fdde99 - MediaCollectionViewCell: Last played indicator for VLCMLMedia
    • 5563d720 - MovieCollectionViewCell: Last played label
    • e2ce0c18 - MediaCollectionViewCell: Fixed CheckImageView on selection bug

    Compare with previous version

  • Mohamed Sliem changed title from MediaCategoryViewController: Last Played Playlist Indicator to MediaCategoryViewController: Last Played Playlist Media Indicator

    changed title from MediaCategoryViewController: Last Played Playlist Indicator to MediaCategoryViewController: Last Played Playlist Media Indicator

  • Mohamed Sliem changed the description

    changed the description

  • Diogo Simao Marques
    • Resolved by Diogo Simao Marques

      Two additional remarks:

      1. Regarding the changes you will have to make to the LastPlayedPlaylistModel and LastPlayedPlaylistMedia structs, we could maybe add them to an already existing file (perhaps the PlaylistModel one) to avoid the addition of such a small file.
      2. You maybe forgot some commits, I couldn't manage to display the last played label on the proper media inside the last played playlist.
  • Mohamed Sliem added 35 commits

    added 35 commits

    • e2ce0c18...aa8a02e5 - 3 commits from branch videolan:master
    • aa8a02e5...8069895a - 22 earlier commits
    • e659dc3d - MovieCollectionViewCell: Last played label
    • 60665459 - MediaCollectionViewCell: Fixed CheckImageView on selection bug
    • 3e647aaa - MediaCollectionViewCell: Updated Last played indicator logic
    • 6e50d66d - MediaCollectionViewCell: Fixed coding style
    • 5dcac303 - MovieCollectionViewCell: Fixed Coding Style
    • a622606a - VLCPlaybackService: Limited PlaybackWillStop Observation
    • 8d989f16 - MediaCategoryViewController: Limited Lastplayed media observation
    • f2c56678 - LastPlayedPlaylistModel: Removed unnecessary initializer
    • cf5694f8 - MediaCategoryViewController: LastPlayedPlaylistModel nil-safety
    • 8a879a49 - MediaCategoryViewController: Refactored checking last played playlist cell

    Compare with previous version

  • Mohamed Sliem added 43 commits

    added 43 commits

    • 8a879a49...394bfc5e - 5 commits from branch videolan:master
    • 394bfc5e...436f11dc - 28 earlier commits
    • f7806390 - MediaCategoryViewController: Limited Lastplayed media observation
    • 4a915656 - LastPlayedPlaylistModel: Removed unnecessary initializer
    • 03778152 - MediaCategoryViewController: LastPlayedPlaylistModel nil-safety
    • 505c3d75 - MediaCategoryViewController: Refactored checking last played playlist cell
    • eccb30ca - MediaCategoryViewController: Removed unneeded OS checking
    • 635e0339 - MediaCollectionViewCell: Handled updating newLabel
    • 01ea8130 - MediaCategoryViewController: Refactored observing last played playlist
    • 338ae522 - VLCConstants: Added CurrentPlaylistQueueIds Key
    • ba2ed2df - PlaylistModel: Added CurrentPlaylistQueueInfo model
    • 73443e5f - MediaCategoryViewController: Ability to indicate last played media from

    Compare with previous version

  • Author Contributor

    I fixed the newLabel bug and added the ability to correctly indicate the last played media for a given playlist in case the user added many different media from different playlists to the player queue.

    lastPlayedInd

    Edited by Mohamed Sliem
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading