1
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2024-06-30 00:53:19 +00:00
Commit Graph

95 Commits

Author SHA1 Message Date
Jared Fantaye
bc29f40d69 Implemented the suggested changes 2023-02-09 21:18:21 +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
Isira Seneviratne
ee6a279596 Remove unused methods in HistoryRecordManager. 2022-08-06 05:09:54 +05:30
Isira Seneviratne
47f58040d1 Make OnClickGesture an interface. 2022-08-01 06:47:00 +05:30
Stypox
085d1e0d38
Actually fix wrong view count 2022-07-01 16:07:19 +02:00
TacoTheDank
cf213affa2 Annotate some NonNulls, some lint cleaning 2022-03-18 13:15:44 -04:00
TobiGr
277f21d5b2 Move Classes related to InfoItemDIalog into own package 2022-02-20 20:17:04 +01:00
TobiGr
fd0d76e866 Apply feedback
Return this in InfoIrtemDialog.Builder methoods.
Move null checks for InfoIrtemDialog.Builder into constructor.
Fix and add some more docs.
2022-02-20 20:17:04 +01:00
TobiGr
646d8f431c Use identical method names for creating the InfoItemDialog in Fragments 2022-02-20 20:17:04 +01:00
TobiGr
962fe9c36d Use Context instead of Activity
Improve docs
2022-02-20 20:17:04 +01:00
TobiGr
50e2385e82 Add default entries automatically 2022-02-20 20:17:04 +01:00
TobiGr
1cd3ef5dba Extract entries into beginning and end category 2022-02-20 20:17:04 +01:00
TobiGr
80157fc1be Refactor generating InfoItemDialog's
This commit refactors the way `InfoItemDialog`s are generated. This is necessary because the old way used  the `StreamDialogEntry` enum for most of the dialogs' content generation process. This required static variables and methods to store the entries which are used for the dialog to be build (See e.g.`enabledEntries` and methods like `generateCommands()`). In other words, `StreamDialogEntry` wasn't an enumeration anymore.

To address this issue, a `Builder` is introduced for the `InfoItemDialog`'s genration. The builder also comes with some default entries and and a specific order. Both can be used, but are not enforced. 

A second problem that introduced a structure which was atypical for an enumeration was the usage of non-final attributes within `StreamDialogEntry` instances. These were needed, because the default actions needed to overriden in some cases.

To address this problem, the `StreamDialogEntry` enumeration was renamed to `StreamDialogDefaultEntry` and a new `StreamDialogEntry` class is used instead.
2022-02-20 20:17:04 +01:00
Stypox
71c5aaa11e
Do not show enqueue button if play queue not ready 2022-01-27 17:11:16 +01:00
Stypox
8a5e2ffa57
Fix order of local search results 2021-12-08 13:59:32 +01:00
Stypox
9e44053e22
Merge pull request #7160 from nschulzke/mark-as-watched-everywhere
Enable Mark as Watched in all the other playlist fragments.
2021-11-13 20:37:59 +01:00
Nathan Schulzke
dee32c3dc5 Factor out shouldAddMarkAsWatched as a shared function 2021-11-13 10:18:17 -07:00
TacoTheDank
51837ce36f Get rid of setUserVisibleHint 2021-10-16 15:33:45 -04:00
TobiGr
658d988254 Simplify code and add annotations 2021-10-10 20:33:05 +02:00
Nathan Schulzke
108af48b76 Enable Mark as Watched in all the other playlist fragments. 2021-09-23 21:39:47 -06:00
z3r0r4
70354eb73e
Add play next to long press menu & refactor enqueue methods (#6872)
* added mvp play next button in long press menu; new intent handling, new long press dialog entry, new dialog functions, new strings

* changed line length for checkstyle pass

* cleaned comments, moved strings

* Update app/src/main/res/values/strings.xml

to make long press entry more descriptive

Co-authored-by: opusforlife2 <53176348+opusforlife2@users.noreply.github.com>

* Update app/src/main/res/values/strings.xml

Co-authored-by: Stypox <stypox@pm.me>

* replace redundant nextOnVideoPlayer methods

Co-authored-by: Stypox <stypox@pm.me>

* add enqueueNextOnPlayer and enqueueOnPlayer without selectOnAppend and RESUME_PLAYBACK/ deprecate enqueueNextOn*Player and enqueueOn*Player methods
add getPlayerIntent, getPlayerEnqueueIntent and getPlayerEnqueueNextIntent without selectOnAppend and RESUME_PLAYBACK/ deprecate those with
add section comments

* removed deprecated methods
removed redundant methods

* removed deprecated methods
removed redundant methods

* replaced APPEND_ONLY, removed SELECT_ON_APPEND / replaced remaining enqueueOn*Player methods

* now works with playlists

* renamed dialog entry

* checking for >1 items in the queue using the PlayerHolder

* making enqueue*OnPlayer safe to call when no video is playing (defaulting to audio)

* corrected strings

* improve getQueueSize in PlayerHolder

* long press to enqueue only if queue isnt empty

* add Whitespace

Co-authored-by: Stypox <stypox@pm.me>

* clarify comments / add spaces

* PlayerType as parameter of the enqueueOnPlayer method
add Helper method

* using the helper function everywhere (except for the background and popup long-press actions (also on playlists, history, ...)), so basically nowhere
/ passing checkstyle

* assimilated the enqueue*OnPlayer methods

* removed redundant comment, variable

* simplify code line

Co-authored-by: Stypox <stypox@pm.me>

* move if

* replace workaround for isPlayerOpen()

Co-authored-by: Stypox <stypox@pm.me>

* replaced workarounds (getType), corrected static access with getInstance

* remove unused imports

* changed method call to original, new method doesnt exist yet.

* Use getter method instead of property access syntax.

* improve conditional for play next entry

Co-authored-by: Stypox <stypox@pm.me>

* show play next btn in feed fragment

Co-authored-by: Stypox <stypox@pm.me>

* add play next to local playlist and statistics fragment

Co-authored-by: Stypox <stypox@pm.me>

* formating

Co-authored-by: Stypox <stypox@pm.me>

* correcting logic

Co-authored-by: Stypox <stypox@pm.me>

* remove 2 year old unused string, formating

Co-authored-by: Stypox <stypox@pm.me>

* correct enqueue (next) conditionals, default to background if no player is open. Dont generally default to background play.

* remove player open checks from button long press enqueue actions

* improve log msg

* Rename next to enqueue_next

* Refactor kotlin

Co-authored-by: opusforlife2 <53176348+opusforlife2@users.noreply.github.com>
Co-authored-by: Stypox <stypox@pm.me>
2021-09-18 11:22:49 +02:00
ktprograms
76803bfcb1 Save channelUrl to Database if it doesn't exist 2021-08-13 18:02:53 +08:00
Nathan Schulzke
dc0a28b93d Upsert the complete info if we fetch it for marking as watched 2021-07-31 09:50:41 -06:00
Nathan Schulzke
0e12cdea7c Save the fetched duration to the database so that it can render the view correctly. 2021-07-29 20:59:23 -06:00
Nathan Schulzke
bdd16e06e0 Add comments describing the purpose of the markAsWatched method 2021-07-28 08:25:39 -06:00
Nathan Schulzke
4c632810ec Fetch the stream info via a network request if no duration is found when attempting to mark as watched. 2021-07-27 15:21:56 -06:00
Nathan Schulzke
2b41f710a8 Change played to watched 2021-07-27 13:26:51 -06:00
Nathan Schulzke
7fd2ebc252 Add ability to mark an item as played 2021-07-26 20:51:41 -06:00
evermind
48c2c156cb convert PlayerHolder to Singleton, handle context within, bugfix ServiceConnection leak
- bugfix: have ServiceConnection created only once!

- select the context within the PlayerHolder to start, stop, bind or unbind the service
  -> we have to make sure the Service is started AND stopped within the same context
  -> so let PlayerHolder be the one to select the context

- remove removeListener() and replace the call with setListener(null)
- Compatibility: use ContextCompat.startForegroundService instead of startService()
2021-07-06 12:31:26 +02:00
TacoTheDank
79deff3261 Annotate some overridden methods and parameters as NonNull 2021-06-19 18:37:02 -04:00
Tobi
be676ad93c
Merge pull request #3371 from mauriciocolli/feed-hide-played-items
Add ability to hide played items in a feed
2021-06-18 09:18:48 +02:00
Stypox
2142f05a88
Fix hiding finished streams in groups; new stream state validity condition
Consider stream state valid also if >1/4 of video was watched
2021-06-14 19:01:01 +02:00
TiA4f8R
d6decc05d7
Move some classes to a new subpackage and adress requested changes
Rename URLHandler and KoreUtil classes to InternalUrlsHandler and KoreUtils.
Move InternalUrlsHandler, KoreUtils, TextLinkfier, ShareUtils classes to external_communication subpackage.
Remove unused param showPreviewText in shareText method of ShareUtils class.
Add initial work to be able to display an image preview of the content shared (not for downloads).
Use a better regular expression to parse timestamps in plain text descriptions.
2021-06-11 12:12:02 +02:00
Stypox
0113ad5e14
Correctly save stream progress at the end of a video 2021-06-09 15:53:51 +02:00
Stypox
360f5ac6f7
Save playback state even if stream is finished and add isFinished() 2021-06-09 15:53:51 +02:00
TiA4f8R
b4d6015464
Add the Open in browser option when long-pressing a stream for local and online playlists and for history 2021-06-03 13:21:31 +02:00
mhmdanas
b2b9938484 Put show channel details option in more long-press menus 2021-05-15 19:20:27 +03:00
krlvm
fd14c8cdce
Fix Dark elements in Light Theme 2021-03-27 17:46:05 +03:00
Stypox
c43bca6007
Add report/solve-recaptcha button in error panel
It will be shown even when nothing could be loaded not due to a network error, and the user can choose to ignore or report it.

Also improve error reporting arguments
Also completely refactor error activity
Also improve some code here and there
2021-03-12 23:21:49 +01:00
Stypox
553b80164b
Move all error-related classes into error package 2021-03-07 17:49:28 +01:00
Isira Seneviratne
98be89a20a Return ViewBinding instead of View in BaseLocalListFragment's getListHeader() and getListFooter() methods. 2021-01-14 11:15:54 +05:30
khimaros
ac59382b84 pass serviceId instead of item, reduce duplication 2021-01-02 11:24:33 -08:00
khimaros
48a5107296 address pull request feedback 2020-12-30 14:45:14 -08:00
khimaros
83faf119a9 add list item to play video on kodi
closes: #5157
2020-12-29 18:53:32 -08:00
Stypox
f0ca916432
Update most dependencies 2020-11-22 14:03:10 +01:00
Isira Seneviratne
340b92e32b Convert ErrorInfo to Kotlin and use the Parcelize annotation. 2020-11-21 12:47:35 +05:30
Stypox
1d42e45d78
Unify all ways of opening VideoDetailFragment 2020-11-08 10:00:27 +01:00
Isira Seneviratne
c745b845c5 Switch to the Java 8 Date/Time API. 2020-11-05 15:02:51 +05:30
Isira Seneviratne
abcacf8c74 Use Comparator's comparing(), nullsLast() and reversed() methods. 2020-11-01 14:44:04 +05:30