When the service is started from the Application class, the app might be still in the background. This is definetly not the case when MainActivity.onCreate() is called.
Fixes#7227
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
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.
Problem is global state in static variable prettyTime. But for performance reasons on Android that is preferred.
Now allow injecting prettyTime dependency by making init function public.
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
Cookie updated whenever ageRestrictedContent setting is changed or
service is changed. Right now there is only a cookie for youtube, but
cookies for other services could be added in the future.
Problems with this approach: Even when the service is set to youtube,
the downloader doesn't only request youtube urls e.g. it also sends
reqeusts to i.ytimg.com, suggestqueries.google.com, and yt3.ggpht.com.
The ageRestrictedContent cookie is not normally sent when sending
requests to these other urls, so doing so might have unknown effects.
Before, the direct value was given to the user, now it uses the parsed
date so we can match the device's language.
To get the relative time from the parsed dates, we use the PrettyTime
library.
Also introduces a debug option to check the service's original value.