Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code improvements for media pages #176

Merged
merged 52 commits into from
Aug 4, 2022

Conversation

YourOrdinaryCat
Copy link
Collaborator

@YourOrdinaryCat YourOrdinaryCat commented Jul 8, 2022

Resolved / Related Issues
Closely related to #160

Details of Changes
This pull request aims to make the app follow the MVVM pattern more closely, which involves:

  • Decoupling: the current way we handle collections is from MainViewModel, which has every single collection. This means we have a lot of boilerplate just to reset filtering and sorting, and it makes saving session state more difficult
  • Less repetition: there's a lot of repeated code when it comes to handling playback and other actions within a given page. This makes the code behind of every page far larger than necessary, which can lead to inconsistencies when triggering different actions

Validation
Not yet finished.

Screenshots / Videos (optional)
Not necessary, at least for now.

@YourOrdinaryCat YourOrdinaryCat self-assigned this Jul 8, 2022
@YourOrdinaryCat
Copy link
Collaborator Author

AlbumsPage has DataTemplate related bugs as of now - mostly hangs and memory leaks when switching, and the template not applying sometimes. Switching to a custom control there is likely necessary, will add that within the next few commits.

@YourOrdinaryCat YourOrdinaryCat marked this pull request as ready for review August 4, 2022 01:22
Copy link
Collaborator

@itsWindows11 itsWindows11 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, but there are some changes that need to be addressed before merging.

Rise Media Player Dev/Helpers/AddToPlaylistHelper.cs Outdated Show resolved Hide resolved
Rise Media Player Dev/UserControls/MediaPageBase.cs Outdated Show resolved Hide resolved
@itsWindows11
Copy link
Collaborator

Also, use the ContextRequested event for the context menu for the lists instead of RightTapped which only handles right click.

@YourOrdinaryCat
Copy link
Collaborator Author

Should be good now.

Copy link
Collaborator

@itsWindows11 itsWindows11 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@itsWindows11 itsWindows11 merged commit 1bc855b into main-(insider_bloom) Aug 4, 2022
@itsWindows11 itsWindows11 deleted the cq/content-pages-improvements branch August 27, 2022 11:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants