Commit Graph

566 Commits

Author SHA1 Message Date
Isira Seneviratne 097d32b684 Migrate to non-transitive R classes. 2024-03-25 15:12:30 +01:00
TacoTheDank 4a7fda95ae
Update miscellaneous libraries 2023-12-23 11:47:57 +01:00
TacoTheDank 76f1e588f7
Utilize BundleCompat and IntentCompat methods 2023-12-23 11:38:40 +01:00
TacoTheDank 00566ed4d4
Fix AndroidX Work deprecation 2023-12-23 11:36:33 +01:00
Stypox 80f33daeeb
Fix OutOfMemory when fetching feed
Reduced memory footprint of FeedUpdateInfo objects. Those objects might stay around for a while and accumulate (up to BUFFER_COUNT_BEFORE_INSERT = 20 at the moment), so in order not to fill up the memory it's better to keep as little data as possible.
Previously ChannelInfo data was stored, causing ReadyChannelTabLinkHandler objects to be also stored uselessly (and those channel tabs contain prefetched JSON data which used ~700KB of memory).
2023-12-20 20:22:45 +01:00
AudricV 9fab0ec94f
Fix crash when setting the masking of the new feed items button if the context is null
As the fragment context can be null in some cases, we have to make sure that
the context is not null before calling
DeviceUtils.hasAnimationsAnimatorDurationEnabled.

If the context is null, the button will now not be hidden automatically.
2023-11-15 19:04:45 +01:00
TobiGr 3d5a8af52b Fix inconsistency when LocalPlaylist is used as MainFragment tab 2023-10-02 02:56:30 +02:00
Yingwei Zheng 1cf670dad9 Fix inconsistency between user interaction and database commit order when re-adding videos to the playlist 2023-10-02 02:56:30 +02:00
Siddhesh Naik e80b6b3057
Add playlist name and video name to playlist sharing content (#10427)
- Currently, only a list of videos separated by newline are added in
  the share content.
- This makes it difficult to identify a specific video in a list of
  Urls.
- Used string resources for the sharing content formats.
- Added a confirmation dialog for users to choose between sharing
  playlist formats.
- Added Playlist name as the header and corresponding video name for
  each video url in following format.

Playlist
- Music1: https://media-url1
- Music2: https://media-url2
- Music3: https://media-url3


Co-authored-by: TobiGr <tobigr@users.noreply.github.com>
2023-09-26 11:11:33 +02:00
Stypox 87dca0f7ec
Separate imageListToDbUrl from choosePreferredImage
imageListToDbUrl should be used if the URL is going to be saved to the database, to avoid saving nothing in case at the moment of saving the user preference is to not show images.
2023-09-22 10:14:44 +02:00
Stypox 35073c780d
Implement better image selection strategy 2023-09-22 10:14:44 +02:00
Stypox 0a8f28b1c6
Add image quality preference 2023-09-22 10:14:43 +02:00
Stypox af2375948d
Support obtaining multiple images from the extractor 2023-09-22 09:57:33 +02:00
TobiGr 0acc3532c9 Remove useless override 2023-09-20 15:42:09 +02:00
TacoTheDank b1faed586d Replace MathUtils.clamp with Kotlin coerceIn 2023-09-19 16:32:37 -04:00
TobiGr 8f83e39970 Fix three memory leaks
Add documentation to BaseFragment.initViews(View, Bundle) and BaseFragment.initListeners()
2023-09-19 00:13:16 +02:00
TobiGr 57eaa1bbe1
Apply review
Co-Authored-By:  Audric V <74829229+AudricV@users.noreply.github.com>
2023-09-18 23:22:32 +02:00
TobiGr 109d06b4bb
Deduplicate code to initialize ClickListeners on playlist controls
Add the separate utility class PlayButtonHelper to handle the initialization of the listeners.
The ClickListeners on playlist controls had different behaviours. This commit fixes that.

The commit also refactors the way how the app determines whether it is started for the first time. The previous version was not clean and recent in this PR caused it to fail.
2023-09-18 23:22:32 +02:00
TobiGr 6ab8716e69
Extract actual feed loading code into separate method
Increase readability
2023-09-18 23:22:32 +02:00
Stypox 78b4b9441e
Update NewPipeExtractor and adapt imports 2023-09-18 23:22:32 +02:00
Stypox 1519527356
Fix loading feed when a channel tab is empty 2023-09-18 23:22:32 +02:00
Stypox 6b3a178f2a
Show snackbar with feed loading errors 2023-09-18 23:22:32 +02:00
ThetaDev 28d952a643
feat: filter fetched channel tabs 2023-09-18 23:22:32 +02:00
Stypox c076a0f771
Channels are now an Info
The previous "main" tab is now just a normal tab returned in getTabs().
Various part of the code that used to handle channels as ListInfo now either take the first (playable, i.e. with streams) tab (e.g. the ChannelTabPlayQueue), or take all of them combined (e.g. the feed).
2023-09-18 23:22:32 +02:00
Isira Seneviratne cb00c57009 Set channel icon for stream notifications 2023-07-19 05:52:59 +05:30
TobiGr eeec6fd002 Replace null check with use of NotificationManagerCompat.from 2023-07-17 01:28:55 +02:00
Isira Seneviratne 795bc82c7f Show number of new streams in the collapsed summary notification. 2023-07-17 01:28:55 +02:00
Isira Seneviratne 7742c40ac0 Create individual stream notifications for convenience on Android 7.0 and later. 2023-07-17 01:28:55 +02:00
Koitharu 01b46edf1a
Fix crash after feed update 2023-07-14 11:41:52 +03:00
TacoTheDank c1f0a945c0 Clean up AlertDialogs 2023-07-11 21:54:10 -04:00
Isira Seneviratne acebabd028 Use AndroidX's PendingIntentCompat class. 2023-04-13 10:53:46 +05:30
Stypox 23a20712da
Merge pull request #9707 from Jared234/1473_remove_duplicates_from_playlist
Remove duplicates from playlist feature
2023-02-28 22:14:01 +01:00
Stypox 43f46e29ad
Update app/src/main/java/org/schabi/newpipe/local/playlist/LocalPlaylistFragment.java 2023-02-28 21:40:11 +01:00
Stypox 7617f8cdc7
Update app/src/main/java/org/schabi/newpipe/local/playlist/LocalPlaylistFragment.java 2023-02-28 21:35:57 +01:00
Stypox 2e3490bce2
Merge pull request #9747 from Jared234/9126_remove_partially_watched_from_feed
Added option to remove partially watched videos from the 'Whats new' feed
2023-02-28 19:10:11 +01:00
Jared Fantaye 1dd0930b83 Fixed some small issues 2023-02-28 17:30:17 +01:00
Jared Fantaye 265de55a07 Merge remote-tracking branch 'origin/1473_remove_duplicates_from_playlist' into 1473_remove_duplicates_from_playlist 2023-02-28 16:44:13 +01:00
Jared Fantaye d8ed2c8503 Refactoring removeDuplicates function and preventing concurrent calls. 2023-02-28 16:43:58 +01:00
Stypox 2ee4c6e289
Merge pull request #9728 from mahendranv/channel_card
Larger channel cards in search results
2023-02-26 13:43:09 +01:00
Stypox 097c2368f4
Merge pull request #8180 from Trust04zh/fix-4053-8176
Make UI behavior for playback information display more consistent
2023-02-26 13:22:13 +01:00
Jared Fantaye 9067c770a7 Made some small code improvements 2023-02-25 22:14:49 +01:00
Jared Fantaye 68ea99d6e6 Made some small code improvements 2023-02-09 23:17:36 +01:00
Jared Fantaye bc29f40d69 Implemented the suggested changes 2023-02-09 21:18:21 +01:00
Jared234 42fb13f17a
Merge branch 'dev' into 1473_remove_duplicates_from_playlist 2023-02-09 20:47:10 +01:00
Mahendran 75292e099c Larger channel cards in search results
- Thumbnail larger (100dp) than the usual (92dp) throughout the app
- Description lint count is 8 (normally 3)
2023-02-09 06:15:22 +05:30
Trust_04zh e947e86eae
Make positions in list depend on watch history, remove confusing animations
The following is the list of all commits squashed together:

Regain function for option `Positions in lists`

use option `Resume playback` to control display of progress info in VideoDetailFragment, remove this (extra) function from option `Positions in lists`.
remove extra check for live streams, live streams updates just as non-live streams.

fix #8176 by eliminating exit delay

Regain function for option `Positions in lists`

update code with developer's comments

 apply static import to methods in util class DependentPreferenceHelper

Regain function for option `Positions in lists`

use option `Resume playback` to control display of progress info in VideoDetailFragment, remove this (extra) function from option `Positions in lists`.
remove extra check for live streams, live streams updates just as non-live streams.

fix behavior for displaying progress bar when autoplay off but video resume on

not to retrieve unnecessary states when position in lists disabled

fix mistake in code

simplify conditional logic

update doc comment and remove unused method

Fix not showing duration if position indicators disabled

Positions in lists only depends on watch history
2023-02-07 09:48:18 +01:00
Jared234 3ff4b713e8
Merge branch 'dev' into 9458_faulty_playlist_thumbnail_update 2023-02-05 20:45:44 +01:00
Jared Fantaye 68097568d5 Fixed the bug by replacing the thumbnail_url with the thumbnail_stream_id 2023-02-05 20:32:34 +01:00
Jared Fantaye cd8d57040c Implemented the feature using multiple checkboxes 2023-02-04 18:48:27 +01:00
Jared Fantaye 9c82441c19 Implemented the feature and fixed some small issues 2023-02-01 23:10:31 +01:00