Commit graph

46 commits

Author SHA1 Message Date
Damontecres
f77d345abf
Allow null ItemTrackModification from DB 2025-12-16 13:52:44 -05:00
damontecres
ebfc00c016
Always save series audio & subtitle preferences regardless of preferred languages (#473)
## Description

This PR adjust the logic for audio & subtitle track selection for TV
series. Instead of only saving for future episodes if the newly selected
track is a different language than the user's preferred, always save it.

Basically this means if you change the audio or subtitle language for an
episode, the same audio or subtitle language will be used for future
episodes (if available).

Also, fixes the "default" subtitle mode to take the user's preferred
language into consideration.

## Issues
Follow up to https://github.com/damontecres/Wholphin/issues/378 &
https://github.com/damontecres/Wholphin/issues/427

Fixes #469
2025-12-15 12:15:17 -05:00
damontecres
ab8bbf2bd7
MPV: Adjust subtitle delay/offset (#470)
**This is for MPV playback backend only!** Since this only works in MPV
for now, the option is not shown if using ExoPlayer.

Adds a setting (the gear icon during playback) to adjust the subtitle
delay.

A negative delay shows subtitles sooner. A positive delay shows them
later. For example, if a subtitle is supposed to show between
1000ms-2000ms, a negative 250ms delay will show it at 750ms-1750ms
instead.

The delay is persisted between plays of the same media & subtitle track.

Ref: #12 


![subtitle_delay](https://github.com/user-attachments/assets/824e3a28-650a-4619-9535-b67addaabf1e)
2025-12-15 10:06:36 -05:00
damontecres
d2e1c4683d
Only use server provided aspect ratios if >0 (#453)
Fixes #451
2025-12-13 16:43:49 -05:00
Damontecres
652becd685
Disable pin check 2025-12-12 19:16:43 -05:00
damontecres
c5c0dff705
Fix subtitle smart mode to check chosen audio language (#420)
Fixes how the smart subtitle mode logic works

Fixes #406
2025-12-11 12:52:21 -05:00
damontecres
0f4254c6ec
Persist audio & subtitle track changes for series if in different language (#405)
This only applies if the user has set a preferred audio and/or subtitle
language on the web UI!

If the user chooses an audio/subtitle track that is a different language
than their preferred, it will be remembered for that series. Playback of
future episodes of the series will pick a matching language.

The audio & subtitle selections are independent. You can make the choice
before playback or during playback.

Closes #378
2025-12-11 10:16:45 -05:00
damontecres
fa141adc60
Ignore auto sign in if user has PIN (#392)
If the current user has a PIN, the sign in automatically setting is
ignored if the app is put in the background or restarted.

Follow up to #356 &
https://github.com/damontecres/Wholphin/issues/321#issuecomment-3621312496

I think the PIN protection needs some more thought overall.
2025-12-07 17:48:46 -05:00
damontecres
9e7742034a
Update style for ktlint 1.8 (#390)
Updated `ktlint`, so lots of code style changes, no user facing changes
2025-12-06 18:11:07 -05:00
damontecres
a197f6911b
Fixes to user interface (#374)
- Fixes a crash if the same person has multiple roles in an item
- Better tab focus behavior, especially on series pages
- Use consistent series production years on all pages
- Slightly decrease size and increase space on home page
2025-12-05 11:35:50 -05:00
damontecres
8ea84b3efe
Add setting to protect a user profile with a PIN (#356)
Allows for setting a per-user profile PIN that must be entered to switch
to the user. The PIN is a sequence of directional buttons, ie D-Pad
left/right/up/down.

This PIN is per device per user per server. The PIN is stored locally
and not sent nor shared with the server. If you forget your PIN, can
still access the app using server credentials which also removes the
PIN.

Additionally, there is another setting to disable automatically sign in.
When enabled (default) the last user is automatically restored, even if
there is a PIN. If disabled, a server & user must always be selected
when opening the app.

Closes #268
Closes #321
2025-12-04 14:37:27 -05:00
damontecres
384401a72c
Customize display of library grid pages (#368)
## Details

Adds options to customize how grid pages are displayed. Every grid page
can be individually customized.

The options are saved per user on the device and restored when
navigating back to the page. The pages that support it have a new button
next to the sort/filter buttons and changes are updated live.

The options are:
* Primary or Thumb image
* Aspect ratio
* Show details header w/ backdrop (similar to the one on the home page)
* Number of columns
* Spacing between cards
* Card image content scale (eg Fit, Fill, Crop, etc)

Note: the Genre tabs' grids cannot be customized yet

### Other changes
- Nav drawer now opens over top of content instead of pushing it
- Images for most cards are fetched with actual fill size

### Possible future work
* Customize Genre grids
* Add more image types, banners?
* Add similar customization options to pages with rows, eg Home page and
Recommended tabs

## Example

For example, this is a movie library using thumb images with 8 columns
and reduced spacing. It also shows the details header

## Issues
Closes #186
Related to #72
2025-12-04 12:20:50 -05:00
damontecres
56bf3cb7a0
Optimizes recommended content & image caching (#359)
## Details
This PR contains a number of optimizations

### Images
Updates to request images with maximum sizes

The max sizes are estimates on the maximum number of pixels that will be
actually displayed. This means the server is downscaling large images
which means 1) better quality downscaling and 2) smaller images sent
over the network and cached

This should mean slightly better quality images and more images that can
be cached locally

### Paging
Reduces network calls when fetching paginated data, ie grid pages and
some rows. This PR combines the total record count & first page queries
which slightly reduces total time to load paginated data.

Additionally, on movies/tv show recommended pages, the rows now only
fetch a limited number of items (same as number on home page). While
they previously fetched using pagination, there is an overhead required
to paginate requests, so this is slightly faster.

### Async recommended fetching
On movies/tv show recommended pages, the rows are now fetched completely
separately from each other. Previously, the rows were requested
separtely, but each was only added to the UI in order as each completed.
Now they will add as the data arrived.

Note: Top unwatched TV shows is still very slow on `10.11.x`, see #204


### Image cache

The local, on-disk image cache size is increased from 100mb to 200mb.
Combined with the smaller images, this covers about 1500-2000 poster
images, but will vary by server.

The cache size is now also configurable in advanced settings from 25mb
to 1000mb. Additionally, you can see how much of both the disk and
memory caches are in use.

## Issues
Closes #330 
Related to #120
2025-12-02 16:00:21 -05:00
damontecres
7be4fb5fdf
Fix possible TV guide crash & update Play All libraries (#315)
- Fixes a possible crash if the server has Live TV enabled, but no
channels
- Disable Play All/Shuffle for Collections "library"
2025-11-24 11:40:15 -05:00
damontecres
78e7eb421f
Add ability to filter libraries, collection, etc (#308)
Adds a button to filter contents next to the sort button on grid pages

The filters are saved and restored you return to the page. It works with
#278, playing the filtered items in the sorted order.

The drop down menus for both sorting & filtering are updated to closer
match the overall look.

Filters for:
- Played or unplayed
- Favorite or not
- Genres
- Community (star) rating
- Parental rating
- Video type (HD vs SD, etc)
- Release year and/or decade
2025-11-23 10:40:18 -05:00
damontecres
20ab146c97
Update device profile for Jellyfin 10.11 (#293)
## Details

This PR updates the device profile used by ExoPlayer. It should more
accurately report support for HDR formats.

## Acknowledgements
This PR contains a commit (cd6351912af72d274b0baf50af4d777b986f0f46)
that has code copied and slightly modified from
https://github.com/jellyfin/jellyfin-androidtv `v0.19.4`.

Major acknowledgement & credit to the Jellyfin Android TV developers for
this code!

## Issues
Related to #15
2025-11-21 20:16:49 -05:00
damontecres
ccc900cee7
Don't query for Live TV info if user does not have access (#286)
Fixes #281
2025-11-21 13:15:52 -05:00
damontecres
45567bf4eb
Variety of UI changes for grids, home page order, & tv guide (#272)
## Details
This PR ended up being larger than I meant. It contains some UI changes
and code organization.

## TV & DVR
- Uses the "Recordings" library position to order "Recently added in
Recordings" instead of Live TV position
- The times at the top of the TV guide are more distinguishable from
each other
- Removes the duplicate title on the Live TV->Recordings tab

## Other libraries
- Bare-bone support for "Music Video" libraries. Full support for "Music
Video" is work-in-progress in #267, but the libraries should be
browseable now.
- Bare-bone support for "Other" (aka Mixed Movies & TV Shows) libraries.
Note: this type of library is considered [broken and
deprecated](https://jellyfin.org/docs/general/server/media/mixed-movies-and-shows),
so this won't be expanded any further


## Grids
Updates various grid types to use poster vs wide cards. For example,
Favorite TV Episodes will use episode images in a wide card now.

## Issues
Closes #249 
Closes #271
2025-11-20 17:00:11 -05:00
damontecres
4517dcd0cf
Simplify PlaybackViewModel (#252)
`PlaybackViewModel` was becoming very unwieldy at over 1,300 LOC. This
PR breaks it up and simplifies some fields so it's easier to work with.

There are no user facing changes
2025-11-18 19:18:38 -05:00
Damontecres
037e846599
Revert "Use useSeriesForPrimary"
This reverts commit f5f75f9e9e8f3316c689b85d3b8781c932a7c0ff.
2025-11-17 16:12:59 -05:00
damontecres
a9f2e684f1
Add logo to playback overlay (#172)
## Details

Adds the logo (if available) to the upper left corner of the playback
controls overlay.

I am still experimenting with how logos can be used on the details
pages. It's problematic because of the variety of colors, eg dark logos
can be hard to see on the dark background.

## Issues
Related to #92

## Screenshot
<img width="1280" height="771" alt="logo_playback Large"
src="https://github.com/user-attachments/assets/c6cb43fe-f3bc-42a4-9ef4-0397267e3073"
/>
2025-11-17 14:14:35 -05:00
damontecres
93d82a263d
Show extras for Movies & TV Shows (#224)
## Description
Shows local extras (clips, interviews, etc) for movies and tv shows

Extras are grouped by type and clicking on the type will go to a grid
page listing all of the items. However, if there is just one of that
type, it is shown in-line.

Trailers still have on their own row. And theme songs & theme videos are
not shown.

## Issues
Closes #123
2025-11-15 13:25:44 -05:00
Damontecres
00521578d5
Another fix for server/user list 2025-11-14 14:01:20 -05:00
damontecres
b7cb6efc4f
Dev: Move services into their own package (#214)
Moves service classes into their own files and package for easier
organization and discovery

No user facing changes in the PR
2025-11-13 19:39:37 -05:00
damontecres
19b712d54b
More favorite tabs & add people to favorites (#210)
Adds Video, Playlists, & People tabs to the favorites page

Also adds ability to add people to favorites via context menu or on
their page

Closes #199
2025-11-13 16:12:42 -05:00
Damontecres
655720fc05
Small fix for deleting current server or user 2025-11-13 11:52:52 -05:00
damontecres
58395e9adf
Refactoring switching server or user (#205)
Now when initiating a user or server switch, you can't back out of it
and must select a user/server. This will be useful when PIN code are
implemented down the road.

The app will now disconnect the web socket when backgrounded.

Also lots of internal refactoring
2025-11-12 17:44:16 -05:00
damontecres
2e3e4e3f5f
Add long clicking context menus everywhere (#202)
Adds long click context menus to just about every card throughout the
app. Previously only a few pages had this.

Closes #196
2025-11-12 15:36:36 -05:00
damontecres
40a8249469
Support basic adding to playlists (#157)
Closes #143 

Adds option in the "More" menu to add the item to a playlist. Can also
create a playlist if needed.
2025-11-04 15:27:26 -05:00
damontecres
13c2bb32d2
Fix favorites not loading (#156)
Fixes bug introduced in #150 that prevented the favorites page from
loading anything

Also remembers the sort for each favorites tab
2025-11-04 13:33:03 -05:00
damontecres
40267be633
Remember library/collection sorting (#150)
Closes #148 
Closes #83

Remember the chosen sort order & direction per user profile on device.
Also adds a few more sort options.

This is only saved on the device and not saved/loaded from the server.
2025-11-03 12:15:41 -05:00
damontecres
78322ab0a5
Fix deserialization error during login (#145)
Fixes #144 

The error was occurring when querying for server information. The
endpoint used returns information about previous installations and seems
some may be missing a field marked as required in the API. This causes
the deserialization error.

Since the query is just to get the server's name for the UI, we can use
the public server info endpoint instead and also wrap it in a try-catch
since it's not absolutely required.

Additionally, this PR adds exceptions for cases when necessary
information is not available (user id, access token, etc).
2025-11-02 17:28:18 -05:00
damontecres
576c20edff
Fixes & optimizations to series pages (#106)
Simplifies the process for finding the right season id & episode id
after clicking on an episode. This can also improve loading time for
seasons that have a large number of episodes (hundreds).

Also fixes handling for "unknown" seasons which don't have an
index/season number.
2025-10-29 11:02:21 -04:00
damontecres
1a7684b458
Minor UI changes (#75)
* Revert transparent cards from #61
* Don't show queue during playback if playing the final item
* Fix nav drawer collection page from showing everything recursively
* Immediately hide the skip intro button when pressed
2025-10-27 10:17:50 -04:00
damontecres
89b9364807
Dependency updates & removing unused code (#70)
Just bumping dependencies and deleting some unused code. No user facing
changes
2025-10-26 18:17:47 -04:00
damontecres
2667090485
Send crash reports to the server (#65)
Adds ability to send app crash reports to the last connected server. The
app prompts you before sending. There is an advanced settings to disable
this as well.

Additionally, there is an advanced settings button to send the app logs
to the current server.

The resulting reports can be found on the server's web UI under
Dashboard->Logs

If sharing the logs, make sure there's no private information present!
2025-10-26 07:35:42 -04:00
damontecres
fc4954b561
Add ability to customize the navigation drawer menu (#60)
Adds support for customizing the items listed on the left side
navigation drawer menu. Each item can be toggled on/off in settings.

The hidden ones are still accessible under "More" on the nav drawer,
which only appears if some items are hidden.

Additionally, if any of menu items are hidden, their "latest" content
will not appear on the home page.

The setting is stored per user profile.
2025-10-23 15:57:26 -04:00
damontecres
b8202c06ff
Add favorites page (#55)
Closes #38 

Add a nav drawer link to a new favorites page which shows favorited
Movies, TV Shows, and Episodes.

Also adds a button to movies & tv shows to set/unset favorite status.
2025-10-22 16:49:27 -04:00
Damontecres
5bb46bf34b
Fix uuid serialization 2025-10-18 19:56:15 -04:00
damontecres
dc3193e2dc
Various fixes (#33)
Fixes a few issues to prepare for a release.
2025-10-18 18:45:08 -04:00
damontecres
405e170750
Add a debug page (#32)
Click the version in settings 3 times to open this new debug page which
displays internal information such as settings, server info, app info,
and database info. It will also show recently logcat messages.
2025-10-18 15:48:04 -04:00
damontecres
f57fd25f8e
Support playing multiple file versions (#30)
Adds support for playing different versions of a media item.
Additionally, you can pick the audio or subtitle tracks for the chosen
version.

The file with the highest resolution is the default, but you can switch
versions or tracks in the "More" menu.

These choices are persisted across playbacks, just as in #26.
2025-10-18 14:11:06 -04:00
damontecres
6194eba8c5
Remember playback choices & fix some track selection issues (#26)
Remembers changes in playback tracks across playbacks. So, if you change
the audio track, quit the app, and return to the same id, the app will
play the audio track previously chosen.

Additionally, this PR fixes a UI inconsistency when there are multiple
versions of a item. Previously sometimes the audio/subtitle tracks for
wrong version would be shown during playback.
2025-10-17 17:19:44 -04:00
damontecres
bd4d4d5092
Fix some login issues (#23)
Fixes #21

Might also address #18

Fixes an issue with logging using username/password due to network
access on wrong thread exceptions.

Also adds better handling when deleting users or servers, especially if
it's the current one.
2025-10-17 12:05:40 -04:00
damontecres
0e195c18d7
Show genres tab for TV & Movies (#16)
Adds a tab to the TV Show & Movie screens which displays the genres in
that library as a grid.

You can select the genre to see the items in that library for the genre.

This PR also adds backend changes for further filtering to implement
#13.
2025-10-16 16:49:40 -04:00
Damontecres
d39ed721d5
Rebrand 2025-10-15 15:27:30 -04:00