Commit Graph

112 Commits

Author SHA1 Message Date
Isira Seneviratne 6d1c61407d Remove unnecessary method in ChannelFragment. 2022-07-21 08:02:23 +05:30
Stypox 8187a3bc04
Move PlayerType into its own class and add documentation
Also replace some `isPlayerOpen` with direct `playerType == null` checks.
2022-07-13 23:33:18 +02:00
Stypox 76ced59b62
Refactor player: separate UIs and more 2022-07-13 23:25:26 +02:00
Stypox 71e46d1eca
Do not call showContentNotSupportedIfNeeded multiple times 2022-05-06 10:40:08 +02:00
Stypox 238aff7c31
channelContentNotSupported false by default 2022-05-06 10:38:47 +02:00
GGAutomaton 34468c16ad Show "content not supported" if needed 2022-05-04 23:34:07 +08:00
GGAutomaton 2e771cd65a Fix crash when rotating device on unsupported channels 2022-04-04 23:58:39 +08:00
Stypox 6e8c9f92cb
Merge branch 'dev' into pr2335 2022-03-19 22:29:10 +01:00
Stypox 62abfa96b8
Solve Java warning "Raw use of parameterized class" 2022-02-19 17:30:38 +01:00
litetex d3cd3d62b4 Tried to repair #4475 and #3368
* Always recreate the footer so that it's not possible to attach the same instance twice
* Removed support for creating a custom footer as it's never used
* Supply the header with an supplier
  * This might not fix the problem completely as we currently can only create the header once inside Channel, Playlist and RelatedItems-Fragment - allowing creation of multiple headers might be done in the future if the issues still arise
* Other minor fixes
2022-02-17 20:59:36 +01:00
litetex 91c67b085b Code improvements
Removed - partial - stupid code.
2022-02-17 20:59:35 +01:00
Stypox cd95ec4e12
Merge branch 'dev' into pr2335 2021-12-31 19:20:18 +01:00
Stypox 81f740d409
Replace ErrorActivity with ErrorUtil 2021-12-04 10:36:36 +01:00
TobiGr 1130aba7ca Merge remote-tracking branch 'origin/dev' into notifications-1 2021-11-02 07:56:09 +01:00
TobiGr 2d2b96420f Add comments and improve code formatting 2021-10-25 15:06:18 +02:00
TacoTheDank 51837ce36f Get rid of setUserVisibleHint 2021-10-16 15:33:45 -04:00
TobiGr 793ff1a728 Add a few comments and rename a few methods 2021-10-15 20:57:54 +02:00
Tobi 4f7cdcce55
Update app/src/main/java/org/schabi/newpipe/fragments/list/channel/ChannelFragment.java
Co-authored-by: litetex <40789489+litetex@users.noreply.github.com>
2021-10-15 20:22:12 +02:00
TobiGr 64a7978c7f Rename NotificationMode.ENABLED_DEFAULT to NotificationMode.ENABLED 2021-10-15 19:59:06 +02:00
Koitharu fb0473da39
Merge branch 'dev' of https://github.com/TeamNewPipe/NewPipe into feature/notifications 2021-09-20 07:26:01 +03: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
Koitharu a5b9fe4c35
Refactor FeedLoadService to use it within the notification worker 2021-09-07 13:30:26 +03:00
Vasiliy da9bd1d420
Notifications about new streams 2021-09-07 13:30:16 +03:00
Stypox fcef783bbb
Replace UniversalImageLoader with Picasso 2021-08-24 10:56:25 +02:00
TacoTheDank 79deff3261 Annotate some overridden methods and parameters as NonNull 2021-06-19 18:37:02 -04: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
TiA4f8R d85afd6435
Initial work to add the image of the content in the share sheet
Also do some fixes when sharing a file in downloads and some improvements in JavaDocs of ShareUtils class.
2021-06-11 12:12:00 +02:00
camo0112 8f9eaa22e6 Fix display of channel details when it has no videos 2021-04-09 12:45:43 +05:30
Stypox 463dd8ea74
Completely remove return activity, now outdated 2021-03-12 23:21:54 +01:00
Stypox 1fc8e4c148
Optimize imports and solve checkstyle issues 2021-03-12 23:21:53 +01: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
Stypox 327fc742d3
Fix channel subscribe button causing crash in main page tab
The binding was being set to null on onDestroyView() instead of in onDestroy()
2021-01-21 15:31:50 +01:00
Stypox a314f55a17
Move description to a tab alongside related streams and comments 2021-01-17 15:26:25 +01:00
TiA4f8R 79e98db3bd
Apply the requested changes and little improvements
Apply the requested changes, use ShareUtils.shareText to share an stream in the play queue and optimize imports for Java files, using Android Studio functionality.

Apply the requested changes and do little improvements
Apply the requested changes, use ShareUtils.shareText to share an stream in the play queue and optimize imports for Java files, using Android Studio functionality.
2021-01-16 13:23:42 +01:00
TiA4f8R a57fd69fb4
External sharing improvements
Improve NewPipe's share on some devices + fix crash when no browser is set on some devices

Catching ActivityNotFoundException when trying to open the default browser
Use an ACTION_CHOOSER intent and put as an extra intent the intent to
open an URI / share an URI when no default app is set.

Add a LinkHelper class which set a custom action when clicking web links
in the description of a content. This class also helps to implement a confirmation dialog when trying to open web links in an external app.
2021-01-16 13:23:06 +01:00
Isira Seneviratne 920e560b4b Convert AnimationUtils functions to extension functions. 2021-01-16 14:49:37 +05:30
Isira Seneviratne 6039484a02 Use view binding in ChannelFragment. 2021-01-14 11:16:03 +05:30
Isira Seneviratne 979102a2d9 Return ViewBinding instead of View in BaseListFragment's getListHeader() and getListFooter() methods. 2021-01-14 11:15:57 +05:30
Stypox f0ca916432
Update most dependencies 2020-11-22 14:03:10 +01:00
Stypox 1d42e45d78
Unify all ways of opening VideoDetailFragment 2020-11-08 10:00:27 +01:00
Isira Seneviratne b0b0a75c87 Use Collection.removeIf() instead of using Iterator.remove() to remove elements conditionally. 2020-11-01 14:44:07 +05:30
wb9688 87228673b4 Use final where possible 2020-08-16 10:25:09 +02:00
wb9688 5fd7ae33b4 Replace getFragmentManager() with getFM() 2020-08-03 14:47:10 +02:00
Avently d2aaa6f691 Merged the latest changes 2020-07-13 04:17:21 +03:00
wb9688 dd57e246b8 Use getNextPage() instead of getNextPageUrl() 2020-07-07 21:03:24 +02:00
bopol 375e18bec8 subscribe button now match service's main color 2020-05-11 19:29:34 +02:00
wb9688 ae437b1510 Bump NewPipeExtractor 2020-05-08 18:07:52 +02:00
wb9688 235394d96c Don't show sub-channel thumbnail by default 2020-05-08 15:51:21 +02:00
Roy Yosef cc8874b687 Fix PR review
Make all of the uploader section on stream page navigate to the channel page
Extract hard coded strings
Remove redundant spaces
Fix open streams from a channel
Rename "ParentChannel" to "SubChannel"
Config royosef:NewPipeExtractor in app/build.gradle
2020-05-07 20:40:17 +02:00