From f119a368d82efea5f8d86846aecb359df1813a01 Mon Sep 17 00:00:00 2001 From: watermelon42 Date: Wed, 18 Jun 2025 17:19:54 +0300 Subject: [PATCH 1/2] Added support for importing Soundcloud likes as a new tab before `About` in a user's channel. The likes are also retrieved in the feed if the user is subscribed to. --- app/build.gradle | 2 +- .../java/org/schabi/newpipe/util/ChannelTabHelper.java | 7 +++++++ app/src/main/res/values/settings_keys.xml | 6 ++++++ app/src/main/res/values/strings.xml | 1 + 4 files changed, 15 insertions(+), 1 deletion(-) diff --git a/app/build.gradle b/app/build.gradle index 5a5a2be1b..144d29113 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -214,7 +214,7 @@ dependencies { // the corresponding commit hash, since JitPack sometimes deletes artifacts. // If there’s already a git hash, just add more of it to the end (or remove a letter) // to cause jitpack to regenerate the artifact. - implementation 'com.github.TeamNewPipe.NewPipeExtractor:NewPipeExtractor:v0.24.6' + implementation 'com.github.TeamNewPipe.NewPipeExtractor:NewPipeExtractor:v0.24.7' implementation 'com.github.TeamNewPipe:NoNonsense-FilePicker:5.0.0' /** Checkstyle **/ diff --git a/app/src/main/java/org/schabi/newpipe/util/ChannelTabHelper.java b/app/src/main/java/org/schabi/newpipe/util/ChannelTabHelper.java index 8e8d38490..cde6e3fef 100644 --- a/app/src/main/java/org/schabi/newpipe/util/ChannelTabHelper.java +++ b/app/src/main/java/org/schabi/newpipe/util/ChannelTabHelper.java @@ -24,6 +24,7 @@ public final class ChannelTabHelper { switch (tab) { case ChannelTabs.VIDEOS: case ChannelTabs.TRACKS: + case ChannelTabs.LIKES: case ChannelTabs.SHORTS: case ChannelTabs.LIVESTREAMS: return true; @@ -62,6 +63,8 @@ public final class ChannelTabHelper { return R.string.show_channel_tabs_playlists; case ChannelTabs.ALBUMS: return R.string.show_channel_tabs_albums; + case ChannelTabs.LIKES: + return R.string.show_channel_tabs_likes; default: return -1; } @@ -78,6 +81,8 @@ public final class ChannelTabHelper { return R.string.fetch_channel_tabs_shorts; case ChannelTabs.LIVESTREAMS: return R.string.fetch_channel_tabs_livestreams; + case ChannelTabs.LIKES: + return R.string.fetch_channel_tabs_likes; default: return -1; } @@ -100,6 +105,8 @@ public final class ChannelTabHelper { return R.string.channel_tab_playlists; case ChannelTabs.ALBUMS: return R.string.channel_tab_albums; + case ChannelTabs.LIKES: + return R.string.channel_tab_likes; default: return R.string.unknown_content; } diff --git a/app/src/main/res/values/settings_keys.xml b/app/src/main/res/values/settings_keys.xml index 61125c47f..f98639e04 100644 --- a/app/src/main/res/values/settings_keys.xml +++ b/app/src/main/res/values/settings_keys.xml @@ -294,6 +294,7 @@ show_channel_tabs_channels show_channel_tabs_playlists show_channel_tabs_albums + show_channel_tabs_likes show_channel_tabs_about @string/show_channel_tabs_videos @@ -303,6 +304,7 @@ @string/show_channel_tabs_channels @string/show_channel_tabs_playlists @string/show_channel_tabs_albums + @string/show_channel_tabs_likes @string/show_channel_tabs_about @@ -313,6 +315,7 @@ @string/channel_tab_channels @string/channel_tab_playlists @string/channel_tab_albums + @string/channel_tab_likes @string/channel_tab_about show_search_suggestions @@ -390,17 +393,20 @@ fetch_channel_tabs_tracks fetch_channel_tabs_shorts fetch_channel_tabs_livestreams + fetch_channel_tabs_likes @string/fetch_channel_tabs_videos @string/fetch_channel_tabs_tracks @string/fetch_channel_tabs_shorts @string/fetch_channel_tabs_livestreams + @string/fetch_channel_tabs_likes @string/channel_tab_videos @string/channel_tab_tracks @string/channel_tab_shorts @string/channel_tab_livestreams + @string/channel_tab_likes import_export_data_path diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 1015dea08..4a9bfd14b 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -828,6 +828,7 @@ Channels Playlists Albums + Likes About Channel tabs What tabs are shown on the channel pages From 1c0eabf75c7f154fdfff4b8e401a3c542348c3b2 Mon Sep 17 00:00:00 2001 From: watermelon42 Date: Wed, 18 Jun 2025 19:31:58 +0300 Subject: [PATCH 2/2] Updated extractor version to latest commit --- app/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/build.gradle b/app/build.gradle index 144d29113..0e59d524a 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -214,7 +214,7 @@ dependencies { // the corresponding commit hash, since JitPack sometimes deletes artifacts. // If there’s already a git hash, just add more of it to the end (or remove a letter) // to cause jitpack to regenerate the artifact. - implementation 'com.github.TeamNewPipe.NewPipeExtractor:NewPipeExtractor:v0.24.7' + implementation 'com.github.TeamNewPipe.NewPipeExtractor:NewPipeExtractor:71b335128e8b66ecc0cd45379dd11a0865973065' implementation 'com.github.TeamNewPipe:NoNonsense-FilePicker:5.0.0' /** Checkstyle **/