Commit graph

4208 commits

Author SHA1 Message Date
Profpatsch
911d9622bb Player/handleIntent: a few comments 2025-09-06 15:04:06 +02:00
Profpatsch
e696a374e5 Player: Remove unused IS_MUTED intent key
The only use of the key was removed in commit
429ba53016
but the handling logic stayed around. So let’s get rid of it.
2025-09-05 16:57:27 +02:00
Stypox
ea27448612 Even more centralized error handling in ErrorInfo 2025-09-05 12:39:16 +02:00
Stypox
59e6b24042 Merge pull request #12578 from Stypox/better-error-messages 2025-09-04 13:18:40 +02:00
Stypox
4ae091948f Address PR reviews 2025-09-04 13:17:45 +02:00
Isira Seneviratne
75ff9cc82b Merge pull request #12471 from Isira-Seneviratne/Fix-notifications
Fix foreground service issues
2025-09-01 05:05:47 +05:30
Isira Seneviratne
32c1edf8dd Added comments 2025-08-31 22:25:12 +05:30
Stypox
15f89a26dd Fix REPORT in snackbar not opening ErrorActivity if MainActivity not shown
Bug caused by https://github.com/TeamNewPipe/NewPipe/pull/11789
2025-08-30 14:39:23 +02:00
Stypox
fc567dae55 Allow ErrorInfo messages with formatArgs
- ErrorInfo.getMessage() now returns an ErrorMessage instance that can be formatted into a string using a context (this allows the construction of an ErrorInfo to remain independent of a Context)
- now the service ID is used in ErrorInfo.getMessage() to customize some messages based on the currently selected service
- player HTTP invalid statuses are now included in the message
- building a custom error message for AccountTerminatedException was moved from ErrorPanelHelper to ErrorInfo
2025-08-30 14:36:27 +02:00
Stypox
28218408cc Fix ordering of error messages conditions 2025-08-28 17:06:10 +02:00
Stypox
548e59c981 Show better information about player errors 2025-08-28 17:06:09 +02:00
Stypox
c01d1b9434 Add more specific error messages and deduplicate their handling 2025-08-28 17:05:52 +02:00
TobiGr
abf88f06bb Use androidx compat alert dialog 2025-08-27 11:45:31 +02:00
Profpatsch
a9d5bdfa24 Permission: display explanatory dialog for Android > R
On Android > R, ACTION_MANAGE_OVERLAY_PERMISSION always brings the
user to the app selection screen.

https://developer.android.com/about/versions/11/privacy/permissions#manage_overlay

This is highly confusing behaviour from the system, so let’s add an
instruction before navigating to the settings menu.
2025-08-27 11:38:25 +02:00
Stypox
9d04220e62 Add option to delete a download without also deleting file 2025-08-16 16:50:01 +02:00
Tobi
e5cd710a74 Merge pull request #12460 from Isira-Seneviratne/Short-count-refactor
Fix short count formatting for Android versions below 7.0
2025-08-01 10:56:41 -07:00
Stypox
5c57eec8f2 Merge branch 'master' into dev 2025-07-31 23:52:01 +02:00
Stypox
6abe2cb3c7 Update the names of YT kiosks 2025-07-31 23:43:19 +02:00
Stypox
e801022ae9 Show tabs above kiosks in drawer 2025-07-31 23:43:19 +02:00
Stypox
c06dbe52fc Remove DEBUG statements and don't replace yt trending with live
You can use this command to test instead:

adb shell run-as org.schabi.newpipe.debug.pr12450 'sed -i '"'"'s#<int name="last_used_preferences_version" value="8" />#<int name="last_used_preferences_version" value="6" />#'"'"' shared_prefs/org.schabi.newpipe.debug.pr12450_preferences.xml' && adb shell run-as org.schabi.newpipe.debug.pr12450 'sed -i '"'"'s#\]}</string>#,{\&quot;tab_id\&quot;:5,\&quot;service_id\&quot;:0,\&quot;kiosk_id\&quot;:\&quot;Trending\&quot;},{\&quot;tab_id\&quot;:5,\&quot;service_id\&quot;:1,\&quot;kiosk_id\&quot;:\&quot;Top 50\&quot;}]}</string>#'"'"' shared_prefs/org.schabi.newpipe.debug.pr12450_preferences.xml'
2025-07-31 23:43:19 +02:00
Stypox
d5a25482db [YouTube] Add icons and strings for new trending pages 2025-07-31 23:43:19 +02:00
TobiGr
07b0c92798 WIP: Add SettingsMigration to change YouTube trending kiosk tab 2025-07-31 23:43:19 +02:00
Stypox
028cd9d7b8 Merge branch 'release-0.28.0' into dev 2025-07-30 11:42:06 +02:00
Isira Seneviratne
cab9028420 Remove NewApi suppression 2025-07-29 06:18:27 +05:30
Stypox
a124543144 Merge pull request #12470 from litetex/cleanup-PlayerHelper-localization 2025-07-28 15:30:07 +02:00
Stypox
e12376bad6 Fix player formatters resetting too early on language change
formatters() is called again by the player before the user has a chance to click on the language in the language chooser.

So the correct solution would probably be to attach to https://developer.android.com/reference/android/content/Intent#ACTION_LOCALE_CHANGED, but let's keep it simple. I added `PlayerHelper.resetFormat();` in `ContentSettingsFragment.onDestroy()` and it works. It will mean the player formatters will be reset every time the user exits content settings, but whatever.
2025-07-28 15:29:06 +02:00
litetex
f86aa0a5a9 Encapsulate Formatters in PlayerHelper
and reset them when the language is changed/changing.
This way they will be re-initialized on the next call.

Also Remove a bunch of outdated/non-thread safe code (STRING_FORMATTER)
2025-07-28 15:11:27 +02:00
litetex
e72db1a816 Remove unused method 2025-07-28 15:11:27 +02:00
litetex
6ac5acd9ff Cleanup `Localization` formatting 2025-07-28 15:11:27 +02:00
litetex
9e2e6f211d Use regions 2025-07-28 15:11:27 +02:00
Stypox
307598fd40 Merge pull request #12455 from TobiGr/nextPage-nullable 2025-07-28 14:52:08 +02:00
Stypox
a46a01d504 Improve null checking further in SearchFragment.handleNextItems 2025-07-28 14:43:46 +02:00
Isira Seneviratne
7de1f6c8e3 Improve scale display 2025-07-28 09:02:52 +05:30
Isira Seneviratne
b4a5960c2f Suppress NewApi 2025-07-27 15:47:06 +05:30
TobiGr
96a995c182 Update USER_AGENT to Firefox 140 ESR 2025-07-27 09:39:53 +02:00
Isira Seneviratne
d1d1e647d6 Update manifest, startForeground call 2025-07-27 11:58:01 +05:30
Isira Seneviratne
2b3de55cef Fix new streams notification issue 2025-07-27 11:31:23 +05:30
Isira Seneviratne
34e55f6eb4 Fix short count formatting for Android versions below 7.0 2025-07-24 07:56:44 +05:30
Michael Zh
fa2421027c Fix compile
Co-Authored-By: Isira Seneviratne <31027858+Isira-Seneviratne@users.noreply.github.com>
2025-07-23 18:49:28 -04:00
Michael Zh
1564a43e8f WIP: Fix compile 2025-07-23 18:45:30 -04:00
Michael Zh
6b4698ac71 Fix error toast crash 2025-07-23 18:45:30 -04:00
Michael Zh
7c85d41aed Specify RECEIVER_EXPORTED/RECEIVER_NOT_EXPORTED for sdk34 2025-07-23 18:45:30 -04:00
TobiGr
6ac41b1e9a Use correct fix for nextPage being null while creating error report in SearchFragment.handleNextItems() 2025-07-22 16:12:02 +02:00
Kouki Badr
e28c6a1373 fix: handle nullable nextPage behavior when searching albums #12401 (#12408)
* fix: handle nullable nextPage behavior when searching albums #12401

* feat: add nullable annotation to newPage attribute in SearchFragment

* Updated more usages of InfoItemsPage#getNextPage. Nullability is already handled in these areas so no other changes needed

---------

Co-authored-by: Siddhesh Naik <siddheshnaik20@protonmail.com>
2025-07-22 08:58:56 +05:30
litetex
722e290f8f Cleaned up some code related to app language
* Use build constants when possible
* Inline variables
* Don't use var for normal-sized types (that way it's easier to review)
* Split code into methods
2025-07-20 21:52:07 +02:00
Isira Seneviratne
2ea50b203c Clean up imports 2025-07-20 16:43:37 +05:30
Isira Seneviratne
c1a8418b82 Properly handle when system language is selected 2025-07-20 16:27:07 +05:30
Isira Seneviratne
dec82a8a5c Add link for future reference 2025-07-20 05:03:20 +05:30
Isira Seneviratne
15f79507c4 Enable per-app language preferences for Android < 13 2025-07-20 04:50:49 +05:30
Stypox
711312e3b3 Fix state not saved 2025-07-19 20:39:55 +02:00