Commit graph

3289 commits

Author SHA1 Message Date
Eric Xu
158791043e Resolve TODO in indexOf(...)
PlayQueueItem overrides equals and hashCode, so using indexOf is
perfectly fine.
2021-05-24 12:20:19 -04:00
Eric Xu
784c78c89e Rewrite setIndex(int) to pass unit tests
Original did not cover the case of when streams is empty and
documentation does not specify any input restrictions.

There's an ambiguity with broadcasting an event between the
documentation and the actual code (see TODO).
2021-05-24 12:20:19 -04:00
Eric Xu
55da632641 Refactor assignments to field declaration
Assignments that don't require the constructor can be moved out.
2021-05-24 12:20:19 -04:00
Eric Xu
78ff6485a2 Add hashCode() to match equals(other) 2021-05-24 12:20:19 -04:00
Eric Xu
61e2ab4d80 Refactor streams to initialize with values 2021-05-24 12:20:19 -04:00
Eric Xu
8b2b3f8fe2 Refactor ArrayList fields to List 2021-05-24 12:20:19 -04:00
Eric Xu
b4b6726ec8 Refactor and optimize equals
- Remove multiple casts of obj

 - Simply use object equals on the streams because PlayQueueItem’s
   equals already compares urls
2021-05-24 12:20:19 -04:00
TobiGr
14a6130a44 Add support for PeerTube HLS streams 2021-05-23 11:53:35 +02:00
XiangRongLin
51026f6450 Merge pull request #6319 from ATofighi/feat-6039-store-backup-location
Save backup import/export location for future import/exports
2021-05-21 21:08:33 +02:00
Alireza Tofighi
2877c43ecb Invert if condition in ContentSettingsFragment.setImportExportDataPath for better readability 2021-05-21 20:24:57 +04:30
Alireza Tofighi
15873d53c4 Move ContentSettingsFragment.isValidPath to helpers and add unit test for it. 2021-05-21 20:21:58 +04:30
Alireza Tofighi
01f05e2f46 Save backup import/export location for feature import/exports 2021-05-17 21:57:27 +04:30
XiangRongLin
4a6ee0cea5 Merge pull request #6308 from mhmdanas/make-minor-changes
Make some minor changes
2021-05-17 12:14:00 +02:00
XiangRongLin
0458e05fb9 Merge pull request #6312 from ATofighi/fix-6298-report-page-back-not-working
Fix ErrorActivity actionbar back button not working
2021-05-17 12:12:12 +02:00
Isira Seneviratne
31eb99034f Convert Converters to a Kotlin object. 2021-05-16 11:14:15 +05:30
Isira Seneviratne
0755c854db Rename .java to .kt 2021-05-16 11:14:15 +05:30
Alireza Tofighi
5604194123 Fix ErrorActivity actionbar back button not working
The issue is because of R.id.home != android.R.id.home
2021-05-16 02:19:52 +04:30
mhmdanas
d35974a352 Put show channel details option in more long-press menus 2021-05-15 19:20:27 +03:00
mhmdanas
1f98ef54de Make some minor changes 2021-05-15 18:48:16 +03:00
Robin
6debb784b7 TEST: Downgrade ExoPlayer to 2.12 2021-05-14 14:47:53 +02:00
Robin
c1dc93e2d7 Fixed checkstyle 2021-05-14 12:15:48 +02:00
Robin
9cbcb38f47 Add debug option to disable media tunneling 2021-05-14 12:05:52 +02:00
Saurav Rao
f81cd98fb6 Fix trying to delete object not in list (#6127)
* fix trying to delete object by index -1

* correction in checkstyle-supressions.xml

Co-authored-by: camo0112 <56369484+camo0112@users.noreply.github.com>
2021-05-12 14:33:00 +02:00
litetex
63bfdfc242 Fixed player not automatically playing (#6266)
* Fixed player not automatically playing

Should also fix https://github.com/TeamNewPipe/NewPipe/issues/6179

* Added comment
2021-05-12 10:20:39 +02:00
evermind
3bd65af9c0 fix Rotation crash on „Video not available“ page (#5941)
The EmptyFragment should not have a constructor at all.
Now a static methods creates the Fragment and arguments
are handled via a Bundle.
2021-05-05 08:55:54 +02:00
Tobi
a885f75ad2 Merge pull request #6152 from Isira-Seneviratne/Use_Animator_addListener
Use Animator.addListener() extension.
2021-05-04 19:37:03 +02:00
Robin
7210546d6e Fix: fragmentSize is below the minimum (#6238)
noticed logs " CacheDataSink: fragmentSize is below the minimum recommended value of 2097152. This may cause poor cache performance.

this fixes the issue by using ExoPlayers MIN_RECOMMENDED_FRAGMENT_SIZE. Unfortunately that field is private:
aeb306a164/library/core/src/main/java/com/google/android/exoplayer2/upstream/cache/CacheDataSink.java (L123)
2021-05-04 19:08:25 +02:00
Tobi
09c45b8502 Merge pull request #6189 from mhmdanas/fix-some-warnings
Fix some warnings
2021-05-04 18:54:17 +02:00
Tobi
b188cb9d38 Merge pull request #5997 from TeamNewPipe/reChaptcha
Do not set reCaptcha cookie when there is no cookie stored
2021-05-04 18:53:12 +02:00
mhmdanas
2b27f490b6 Actually fix the parentFile warning 2021-04-30 01:02:46 +03:00
mhmdanas
a5014fef67 Fix some warnings 2021-04-28 00:28:36 +03:00
TobiGr
e59d636707 Merge branch 'master' into dev 2021-04-26 19:13:17 +02:00
Tobi
3b9e498be9 Merge pull request #6151 from TeamNewPipe/share-dialog-color
Fix black drawables in night themes in share dialog (RouterActivity)
2021-04-26 11:51:50 +02:00
TobiGr
ac3707c3b0 Fix black drawables in night themes in share dialog (RouterActivity) 2021-04-25 11:36:40 +02:00
TobiGr
a6c1598c32 Fix invisible buffering / loading indicator in player 2021-04-25 11:36:00 +02:00
Isira Seneviratne
905687afcf Use Animator.addListener() extension. 2021-04-24 07:45:12 +05:30
Sub Raizada
b49a6310ad Only show 'download has started' toast when a download has started 2021-04-22 02:45:04 +00:00
camo0112
4a496c1962 user can report the error 2021-04-20 16:21:20 +05:30
camo0112
a70d933edf Error handling in subscribe() in DownloadDialog 2021-04-20 13:06:40 +05:30
Robin
10d4372e19 Merge pull request #6109 from sauravrao637/codeImrovement
Replaced if/else with switch in ErrorActivity, supress false lint warning
2021-04-19 16:45:45 +02:00
camo0112
1f35bd4c82 Replaced if/else with switch 2021-04-19 10:52:52 +05:30
TobiGr
4c4b7e7898 [Bandcamp] Add Radio stream segments
Display channel / creator / artist name when given
2021-04-11 23:14:23 +02:00
XiangRongLin
a77b815662 Merge pull request #5963 from sauravrao637/IssueFix#5959
Fix display of channel details when it has no videos
2021-04-09 11:15:51 +02:00
camo0112
bbc89ffea6 Fix display of channel details when it has no videos 2021-04-09 12:45:43 +05:30
Tom
c70ade0681 Add queue time (#6023)
* Add queue time
2021-04-08 10:41:41 +02:00
Davide Beatrici
829e6170a7 Disable media tunneling on cvt_mt5886_eu_1g (#6024)
* Disable media tunneling on cvt_mt5886_eu_1g

Follow-up to fb49dda602.
2021-04-08 05:21:57 +02:00
Robin
ebedb37477 Merge pull request #6001 from TacoTheDank/appcompat-alertdialog
Migrate rest of AlertDialogs to AppCompat
2021-04-07 05:07:24 +02:00
wangear
c1afc5fcc4 Fix NullPointerException: Attempt to get length of null array in MainActivity (#5999)
* Fixed Unable to start activity ComponentInfo{org.schabi.newpipe/org.schabi.newpipe.MainActivity}: java.lang.NullPointerException: Attempt to get length of null array #5996
issue : #5996
changed :
- Checked null
2021-04-06 14:13:13 +02:00
TacoTheDank
7640aa85c3 Migrate rest of AlertDialogs to AppCompat 2021-04-04 10:26:38 -04:00
TobiGr
a991b2ad4d Do not set reChaptache cookie when there is no cookie stored
In DownloaderImpl#getCookies(String url) the reChaptcha cookie is set if it is not null. For this reason, the cookie was set in every request.
2021-04-04 12:27:12 +02:00