Commit Graph

82 Commits

Author SHA1 Message Date
litetex 672eb34049
Merge pull request #7150 from TacoTheDank/groupieBump
Update Groupie library to 2.9.0
2021-09-30 21:26:58 +02:00
litetex 72dbb9441e Improved streamType check and documentation 2021-09-25 10:31:42 +02:00
TacoTheDank b61d44aaa6 Update Groupie to 2.9.0 2021-09-22 19:08:03 -04: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
Stypox a555aab3e7
Merge pull request #7024 from Stypox/string-fixes
Never use ``android.R.string``s; remove unused ``add`` string
2021-08-31 12:00:07 +02:00
Stypox 039bd5d413
Rename string finish to ok, as its content was "OK" 2021-08-30 16:36:57 +02:00
litetex f18a7c91ca Suppressed warning
There seems to be a bug in the kotlin plugin as it tells you when building that this can't be null:
"Condition 'throwable != null' is always 'true'"
However it can indeed be null as seen in https://github.com/TeamNewPipe/NewPipe/pull/6986#issuecomment-906822218
2021-08-27 16:32:59 +02:00
Stypox 2027b743b4
Merge pull request #6919 from ktprograms/channel-details-all-places
Add Show Channel Details where it's missing
2021-08-24 16:43:21 +02:00
Stypox fcef783bbb
Replace UniversalImageLoader with Picasso 2021-08-24 10:56:25 +02:00
TobiGr 8715e7dd98 Only show "mark as watched" context menu entry when watch history is enabled 2021-08-22 22:15:05 +02:00
ktprograms c248741c00 Add Show Channel Details to Subscription Feed & History 2021-08-13 17:04:10 +08:00
Stypox a3440cc8ef
Merge pull request #6814 from Stypox/channel-grid-span-count
Fix channel item span count for SubscriptionFragment
2021-08-05 14:25:39 +02:00
Stypox a9623f8e6a
Merge pull request #6550 from Douile/fix/clickthrough-feed-refresh
Disable feed click events while refresh overlay is shown
2021-08-01 13:11:24 +02:00
Stypox 644396149b
Fix channel item span count for SubscriptionFragment 2021-07-31 11:02:57 +02:00
Nathan Schulzke f451bdbfa4 Do not add Mark as Watched to a live stream. 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
Stypox 5ba3ef0a25
Fix grid span count calculation; remove duplicate methods 2021-07-19 20:47:50 +02:00
litetex 08d5dfa49c Removed updateRelativeTimeViews when the activity is paused
We don't need to call ``updateRelativeTimeViews`` when the activity is paused, because the user likely won't  notice it.
Despite that onResume already calls ``updateRelativeTimeViews`` so there is no need to do that twice.
2021-07-16 21:04:32 +02:00
Douile 2e053ea25a
Fix crash when refreshing feed 2021-07-11 03:00:32 +01: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
Douile cb1a138140
#6081: Disable feed click handlers during refresh
This patch changes click handlers for feed (Whats new) so that they do
nothing while the feed is refreshing and the items being clicked are not
visible.
2021-06-22 19:42:20 +01:00
Stypox 32df4d39a4
Reshow feed if grid/list view mode changed 2021-06-15 18:40:25 +02:00
Stypox 7145b117cc
Fix long press menu in feed 2021-06-14 19:02:57 +02:00
Stypox 4698d07323
Do not hide feed buttons (show/hide & help) behind three-dots menu 2021-06-14 19:02:57 +02:00
Stypox 0113ad5e14
Correctly save stream progress at the end of a video 2021-06-09 15:53:51 +02:00
Stypox e58feadba9
Remove IN HISTORY label on stream info items 2021-06-09 15:53:51 +02:00
Mauricio Colli e846f69e38
Add ability to hide played items in a feed
- Use components from the new Groupie list library for displaying the
feed list.
2021-06-09 15:53:51 +02:00
TobiGr b57ecae565 Fix getting error cause
Fix error dialog not shown when getting elemets from first subscription failed.
2021-06-08 10:12:36 +02:00
Stypox 89317d4abc Fix feed loading and show a dialog for each invalid subscription 2021-06-08 10:12:36 +02:00
TobiGr c5dd3dc7a9 Improve error message when loading feed
Add name of unavailable channel
2021-06-08 10:12:36 +02:00
TobiGr 6ad4b425e4 Better error handling of terminated channels when loading feed 2021-06-08 10:12:36 +02:00
Isira Seneviratne 74e20a8c52 Use PrettyTime's new formatUnrounded(OffsetDateTime) method.
Also change the types of the relevant variables from Calendar to OffsetDateTime.
2021-03-18 06:38:12 +05:30
Stypox aee0478235
FeedFragment: fix view binding and show loading indicator correctly 2021-03-12 23:21:54 +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 10ec67854e
Fix number being shown instead of corresponding string resorce in feed 2021-01-20 10:44:44 +01:00
Stypox fa7613b8d1
Refactor feed fragment 2021-01-18 11:43:05 +01:00
Stypox d3d05d613d
Fix reload feed button does nothing
initListeners was being called before the bindings were assigned, and therefore the click listener was never setup
2021-01-18 11:42:25 +01:00
Isira Seneviratne 920e560b4b Convert AnimationUtils functions to extension functions. 2021-01-16 14:49:37 +05:30
Isira Seneviratne 87568b6590 Fix the crash that occurs on navigating back to the main fragment. 2021-01-15 06:54:20 +05:30
Stypox 9ee7740fcc
Merge pull request #4947 from Isira-Seneviratne/Convert_ExceptionUtils_to_extensions
Rewrite ExceptionUtils methods as extension functions.
2021-01-14 14:54:37 +01:00
Isira Seneviratne f80e1bd214 Use view binding in FeedFragment. 2021-01-14 11:16:05 +05:30
Isira Seneviratne 486e720e00 Rewrite ExceptionUtils methods as extension functions. 2021-01-11 16:49:45 +05:30
bopol 2b8837609b dynamically get package name
it fixes issues with forks or debug builds, e.g. when you open two newpipe apps (with debug or fork apps), close one notification, it closes all newpipe notifications
fixes https://github.com/TeamNewPipe/NewPipe/issues/4653
2020-12-20 13:52:20 +01:00
Isira Seneviratne 0fe3fe7594 Use ServiceCompat.stopForeground(). 2020-12-19 16:52:17 +05:30
Stypox b66047e084
Fix ktlint errors 2020-11-22 14:03:10 +01:00
Stypox f0ca916432
Update most dependencies 2020-11-22 14:03:10 +01:00
Stypox 66d15ea635
Merge pull request #4893 from okan35/whatsNewSwipeRefresh
Pull to Refresh Feed
2020-11-20 18:13:32 +01:00
TacoTheDank ea5939c1b7 Kotlin lint fixing 2020-11-18 17:45:19 -05:00