From aaecb599517c22154e8c569e1ed872d44e808f9f Mon Sep 17 00:00:00 2001 From: inotia00 Date: Tue, 11 Apr 2023 07:00:36 +0900 Subject: [PATCH] refactor(sponsorblock): reflect the official ReVanced's source code --- .../NextGenWatchLayoutFingerprint.kt | 9 - .../PlayerControllerFingerprint.kt | 2 +- .../patch/SponsorBlockBytecodePatch.kt | 21 +- .../SponsorBlockSecondaryBytecodePatch.kt | 4 +- .../patch/SponsorBlockResourcePatch.kt | 4 +- .../youtube/settings/host/values/strings.xml | 299 ++++++++++-------- .../youtube/settings/values-v21/strings.xml | 3 +- .../sponsorblock/drawable/ic_sb_adjust.xml | 15 +- .../sponsorblock/drawable/ic_sb_compare.xml | 15 +- .../sponsorblock/drawable/ic_sb_edit.xml | 15 +- .../sponsorblock/drawable/ic_sb_logo.xml | 19 +- .../sponsorblock/drawable/ic_sb_voting.xml | 1 - .../host/layout/youtube_controls_layout.xml | 29 +- .../layout/inline_sponsor_overlay.xml | 22 +- .../sponsorblock/layout/new_segment.xml | 106 +++---- .../layout/skip_sponsor_button.xml | 37 ++- 16 files changed, 346 insertions(+), 255 deletions(-) delete mode 100644 src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/fingerprints/NextGenWatchLayoutFingerprint.kt diff --git a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/fingerprints/NextGenWatchLayoutFingerprint.kt b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/fingerprints/NextGenWatchLayoutFingerprint.kt deleted file mode 100644 index 62d57d9d2..000000000 --- a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/fingerprints/NextGenWatchLayoutFingerprint.kt +++ /dev/null @@ -1,9 +0,0 @@ -package app.revanced.patches.youtube.misc.sponsorblock.bytecode.fingerprints - -import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint -import org.jf.dexlib2.util.MethodUtil - -object NextGenWatchLayoutFingerprint : MethodFingerprint( - returnType = "V", // constructors return void, in favour of speed of matching, this fingerprint has been added - customFingerprint = { MethodUtil.isConstructor(it) && it.parameterTypes.size == 3 && it.definingClass.endsWith("NextGenWatchLayout;") } -) \ No newline at end of file diff --git a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/fingerprints/PlayerControllerFingerprint.kt b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/fingerprints/PlayerControllerFingerprint.kt index aa4709fec..b7b311089 100644 --- a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/fingerprints/PlayerControllerFingerprint.kt +++ b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/fingerprints/PlayerControllerFingerprint.kt @@ -4,7 +4,7 @@ import app.revanced.patcher.fingerprint.method.impl.MethodFingerprint object PlayerControllerFingerprint : MethodFingerprint( customFingerprint = { - it.definingClass == "Lapp/revanced/integrations/sponsorblock/PlayerController;" + it.definingClass == "Lapp/revanced/integrations/sponsorblock/SegmentPlaybackController;" && it.name == "setSponsorBarRect" } ) diff --git a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/patch/SponsorBlockBytecodePatch.kt b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/patch/SponsorBlockBytecodePatch.kt index 1567196ed..1ce8deca7 100644 --- a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/patch/SponsorBlockBytecodePatch.kt +++ b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/patch/SponsorBlockBytecodePatch.kt @@ -43,7 +43,6 @@ import org.jf.dexlib2.iface.reference.MethodReference @Version("0.0.1") class SponsorBlockBytecodePatch : BytecodePatch( listOf( - NextGenWatchLayoutFingerprint, PlayerControllerFingerprint ) ) { @@ -57,16 +56,11 @@ class SponsorBlockBytecodePatch : BytecodePatch( INTEGRATIONS_PLAYER_CONTROLLER_CLASS_DESCRIPTOR, "setVideoTime" ) - highPrecisionTimeHook( - INTEGRATIONS_PLAYER_CONTROLLER_CLASS_DESCRIPTOR, - "setHighPrecisionVideoTime" - ) } /* * Inject VideoIdPatch */ - LegacyVideoIdPatch.injectCall("$INTEGRATIONS_PLAYER_CONTROLLER_CLASS_DESCRIPTOR->setCurrentVideoId(Ljava/lang/String;)V") MainstreamVideoIdPatch.injectCall("$INTEGRATIONS_PLAYER_CONTROLLER_CLASS_DESCRIPTOR->setCurrentVideoId(Ljava/lang/String;)V") @@ -137,18 +131,11 @@ class SponsorBlockBytecodePatch : BytecodePatch( * Voting & Shield button */ - arrayOf("ShieldButton", "VotingButton").forEach { - PlayerControlsPatch.initializeSB("$INTEGRATIONS_BUTTON_CLASS_DESCRIPTOR/$it;") - PlayerControlsPatch.injectVisibility("$INTEGRATIONS_BUTTON_CLASS_DESCRIPTOR/$it;") + arrayOf("CreateSegmentButtonController", "VotingButtonController").forEach { + PlayerControlsPatch.initializeSB("$INTEGRATIONS_BUTTON_CLASS_DESCRIPTOR/ui/$it;") + PlayerControlsPatch.injectVisibility("$INTEGRATIONS_BUTTON_CLASS_DESCRIPTOR/ui/$it;") } - // set SegmentHelperLayout.context to the player layout instance - val instanceRegister = 0 - NextGenWatchLayoutFingerprint.result?.mutableMethod?.addInstruction( - 3, - "invoke-static/range {p$instanceRegister}, $INTEGRATIONS_PLAYER_CONTROLLER_CLASS_DESCRIPTOR->addSkipSponsorView15(Landroid/view/View;)V" - ) ?: return NextGenWatchLayoutFingerprint.toErrorResult() - /* * Replace strings @@ -178,7 +165,7 @@ class SponsorBlockBytecodePatch : BytecodePatch( "Lapp/revanced/integrations/sponsorblock" const val INTEGRATIONS_PLAYER_CONTROLLER_CLASS_DESCRIPTOR = - "$INTEGRATIONS_BUTTON_CLASS_DESCRIPTOR/PlayerController;" + "$INTEGRATIONS_BUTTON_CLASS_DESCRIPTOR/SegmentPlaybackController;" lateinit var insertMethod: MutableMethod lateinit var insertInstructions: List diff --git a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/patch/SponsorBlockSecondaryBytecodePatch.kt b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/patch/SponsorBlockSecondaryBytecodePatch.kt index 68f5ca1f6..895150b82 100644 --- a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/patch/SponsorBlockSecondaryBytecodePatch.kt +++ b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/bytecode/patch/SponsorBlockSecondaryBytecodePatch.kt @@ -49,7 +49,7 @@ class SponsorBlockSecondaryBytecodePatch : BytecodePatch() { mutableMethod.addInstructions( targetIndex + 1, """ - invoke-static {v$targetRegister}, Lapp/revanced/integrations/sponsorblock/SponsorBlockUtils;->appendTimeWithoutSegments(Ljava/lang/String;)Ljava/lang/String; + invoke-static {v$targetRegister}, Lapp/revanced/integrations/sponsorblock/SegmentPlaybackController;->appendTimeWithoutSegments(Ljava/lang/String;)Ljava/lang/String; move-result-object v$targetRegister """ ) @@ -66,7 +66,7 @@ class SponsorBlockSecondaryBytecodePatch : BytecodePatch() { mutableMethod.addInstruction( insertIndex, - "invoke-static {p0}, Lapp/revanced/integrations/sponsorblock/player/ui/SponsorBlockView;->initialize(Ljava/lang/Object;)V" + "invoke-static {p0}, Lapp/revanced/integrations/sponsorblock/ui/SponsorBlockViewController;->initialize(Ljava/lang/Object;)V" ) patchSuccessArray[1] = true diff --git a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/resource/patch/SponsorBlockResourcePatch.kt b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/resource/patch/SponsorBlockResourcePatch.kt index 6cae625b5..551ab5782 100644 --- a/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/resource/patch/SponsorBlockResourcePatch.kt +++ b/src/main/kotlin/app/revanced/patches/youtube/misc/sponsorblock/resource/patch/SponsorBlockResourcePatch.kt @@ -84,9 +84,9 @@ class SponsorBlockResourcePatch : ResourcePatch { if (!(view.hasAttributes() && view.attributes.getNamedItem("android:id").nodeValue.endsWith("player_video_heading"))) continue // voting button id from the voting button view from the youtube_controls_layout.xml host file - val SBButtonId = "@+id/sponsorblock_button" + val votingButtonId = "@+id/sb_voting_button" - view.attributes.getNamedItem("android:layout_toStartOf").nodeValue = SBButtonId + view.attributes.getNamedItem("android:layout_toStartOf").nodeValue = votingButtonId break } diff --git a/src/main/resources/youtube/settings/host/values/strings.xml b/src/main/resources/youtube/settings/host/values/strings.xml index c878e4527..89a4b6411 100644 --- a/src/main/resources/youtube/settings/host/values/strings.xml +++ b/src/main/resources/youtube/settings/host/values/strings.xml @@ -1,72 +1,10 @@ - This app uses the API from SponsorBlock - Tap to learn more, and see downloads for other platforms at: sponsor.ajay.app - Integration made by JakubWeg - API MIRROR URL changed - Provided API MIRROR URL is invalid - API MIRROR URL reset - API URL changed - Provided API URL is invalid - API URL reset - Are you looking for changing colors? - Color changed - "You can now change a category's color by clicking on it above." - Invalid hex code - Color reset - What to do with different segments - Enable SponsorBlock - Enable SponsorBlock Mirror - When SponsorBlock API server is taken down, switch mirror API server to default API server - SponsorBlock is a crowd-sourced system for skipping annoying parts in YouTube videos - Enable new segment adding - Switch this on to enable experimental segment adding (has button visibility issues) - Enable voting - Switch this on to enable voting. - General - Adjusting new segment step - This is the number of milliseconds you can move when you use the time adjustment buttons while adding new segment - Change API Mirror URL - "Mirror server address to switch to when SponsorBlock server is taken down. <b>Don't change this unless you know what you're doing.</b>" - Change API URL - "The address SponsorBlock uses to make calls to the server. <b>Don't change this unless you know what you're doing.</b>" - Minimum segment duration - Segments shorter than the set value (in seconds) will not be skipped or shown in the player - Skip count tracking - This lets SponsorBlock leaderboard system know how much time people have saved. The extension sends a message to the server each time you skip a segment - Show a toast when skipping segment automatically - Click to see an example toast - Show time without segments - This time appears in brackets next to the current time. This shows the total video duration minus any segments. - Your private user id - This should be kept private. This is like a password and should not be shared with anyone. If someone has this, they can impersonate you - hrs Please install MicroG MicroG is not found MicroG does not run in the background Enable cloud messaging settings to receive notifications Open MicroG - min - Choose the segment category - "The segment lasts from %02d:%02d to %02d:%02d (%d minutes %02d seconds) -Is it ready to submit?" - Are the times correct? - "You've disabled this category in the settings, enable it to be able to submit" - Do you want to edit the timing for the start or end of the segment? - Invalid time given - Done - Edit timing of segment manually - end - Mark two locations on the time bar first - start - Set %02d:%02d:%04d as the start or end of a new segment? - now - Time the segment ends at - End of segment set - Time the segment begins at - Beginning of segment set - New SponsorBlock segment - Reset Buttoned ads are shown Buttoned ads are hidden Hide buttoned ad @@ -103,7 +41,7 @@ Is it ready to submit?" Default video speed Default video speed is enabled in live stream Default video speed is disabled in live stream - Disable default video speed in live stream + Default Video speed in live stream Chapters haptic feedback is enabled Chapters haptic feedback is disabled Disable chapters haptic feedback @@ -597,87 +535,170 @@ Since these setting is quite outdated, it may not be valid" SponsorBlock SB Channel Whitelist - Sponsorblock server is not responding! - Already read - "It's recommended to read the SponsorBlock guidelines before submitting any segment" - Show me - There are guidelines - Guidelines contain tips and rules about submitting segments + + Enable SponsorBlock + SponsorBlock is a crowd-sourced system for skipping annoying parts of YouTube videos + Show voting button + Segment voting button is shown + Segment voting button is not shown + Show create new segment button + Create new segment button is shown + Create new segment button is not shown + Use compact skip button + Skip button styled for minimum width + Skip button styled for best appearance + What to do with different segments + General + Show a toast when skipping segment automatically + Toast shown when a segment is automatically skipped. Tap here to see an example + Toast not shown. Tap here to see an example + Enable skip count tracking + Lets the SponsorBlock leaderboard know how much time is saved. A message is sent to the leaderboard each time a segment is skipped + Skip count tracking is not enabled + Show video length without segments + Video length minus all segments, shown in parentheses next to the full video length + Full video length shown + Adjust new segment step + Number of milliseconds the time adjustment buttons move when creating new segments + Value must be a positive number + Minimum segment duration + Segments shorter than this value (in seconds) will not be shown or skipped + Your private user id + This should be kept private. This is like a password and should not be shared with anyone. If someone has this, they can impersonate you + User id cannot be blank + Your SponsorBlock JSON configuration that can be imported/exported to ReVanced and other SponsorBlock platforms. This includes your private user id. Be sure to share this wisely + Change API URL + The address SponsorBlock uses to make calls to the server. <b>Don\'t change this unless you know what you\'re doing</b> + + Sponsor + Paid promotion, paid referrals and direct advertisements. Not for self-promotion or free shout-outs to causes/creators/websites/products they like + Unpaid/Self Promotion + Similar to \'Sponsor\' except for unpaid or self promotion. Includes sections about merchandise, donations, or information about who they collaborated with + Interaction Reminder (Subscribe) + A short reminder to like, subscribe or follow them in the middle of content. If it is long or about something specific, it should instead be under self promotion + Intermission/Intro Animation + An interval without actual content. Could be a pause, static frame, or repeating animation. Does not include transitions containing information + Endcards/Credits + Credits or when the YouTube endcards appear. Not for conclusions with information + Preview/Recap + Collection of clips that show what is coming up or what happened in the video or in other videos of a series, where all information is repeated elsewhere + Filler Tangent/Jokes + Tangential scenes added only for filler or humor that are not required to understand the main content of the video. Does not include segments providing context or background details + Music: Non-Music Section + Only for use in music videos. Sections of music videos without music, that aren\'t already covered by another category + + Skip + Skip sponsor + Skip promo + Skip interact + Skip intro + Skip intermission + Skip intermission + Skip outro + Skip preview + Skip preview + Skip recap + Skip filler + Skip non-music + Skip segment + + Skipped sponsor + Skipped self promotion + Skipped annoying reminder + Skipped intro + Skipped intermission + Skipped intermission + Skipped outro + Skipped preview + Skipped preview + Skipped recap + Skipped filler + Skipped a non-music section + Skipped unsubmitted segment + Skipped multiple segments + + Skip automatically + Skip automatically once + Show a skip button + Show in seek bar + Disable + + Data is provided by the SponsorBlock API. Tap here to learn more and see downloads for other platforms + Integration made by JakubWeg + + Can\'t submit the segment: %s + Unable to submit segments (API timed out) + Unable to submit segments (status: %d %s) + Can\'t submit the segment.\nRate Limited (too many from the same user or IP) + Can\'t submit the segment: %s + Can\'t submit the segment.\nAlready exists + Segment submitted successfully + + Unable to vote for segment (status: %d %s) + Unable to vote for segment: %s + Upvote + Downvote + Change category + There are no segments to vote for + + Choose the segment category + Category is disabled in settings. Enable category to submit. + New SponsorBlock segment + Set %02d:%02d:%04d as the start or end of a new segment? + start + end + now + Time the segment begins at + Time the segment ends at + Are the times correct? + The segment lasts from %02d:%02d to %02d:%02d (%d minutes %02d seconds)\nIs it ready to submit? + Mark two locations on the time bar first + Preview the segment, and ensure it skips smoothly + Edit timing of segment manually + Do you want to edit the timing for the start or end of the segment? + Invalid time given + View guidelines - Switched successfully. reload the video - Switching mirror API server to main API server.. + Guidelines contain rules and tips for creating new segments + Follow the guidelines + Read the SponsorBlock guidelines before creating new segments + Already read + Show me + + Stats + Stats temporarily not available (API is down) + SponsorBlock is disabled + Your username: <b>%s</b> + Tap here to change your username + Unable to change username: Status: %d %s + Username successfully changed + You\'re reputation is <b>%.2f</b> + You\'ve created <b>%s</b> segments + SponsorBlock leaderboard + You\'ve saved people from <b>%s</b> segments + Tap here to see the global stats and top contributors + That\'s <b>%s</b> of their lives.<br>Tap here to see the leaderboard + You\'ve skipped <b>%s</b> segments + That\'s <b>%s</b> + Reset skipped segments counter? + %d hours %d minutes + %d minutes %d seconds + %d seconds + Color: + Color changed + Color reset + Invalid color code + Reset color + + Reset + API URL reset + API URL is invalid + API URL changed + sec - Endcards/Credits - Credits or when the YouTube endcards appear. Not for spoken conclusions - Filler Tangent/Jokes - Tangential scenes added only for filler or humor that are not required to understand the main content of the video. This should not include context or background details - Intermission/Intro Animation - An interval without actual content. Could be a pause, static frame, repeating animation - Music: Non-Music Section - Only for use in music videos. Skips parts of the video not in official mixes - Preview/Recap - "Recap of previous episodes, or a preview of what's coming up later in the current video or future videos in the same series. Clips should not provide additional information." - Unpaid/Self Promotion - When there is unpaid or self promotion. This includes specific sections about merchandise, donations, or information about who they collaborated with - Sponsor - Paid promotion, paid referrals and direct advertisements - Interaction Reminder (Subscribe) - When there is a short reminder to like, subscribe, follow or interact with them on any free or paid platform Failed to export settings Settings were successfully exported Import/Export settings - This is your entire configuration that is applicable in the desktop extension in JSON. This includes your Private userID, so be sure to share this wisely. Failed to import settings Settings were successfully imported - Skipped outro - Skipped filler - Skipped intro - Skipped a non-music section - Skipped preview - Skipped a sponsor segment - Skipped self promotion - Skipped sponsor - Skipped annoying reminder - Skipped unsubmitted segment - Skip automatically - Skip automatically once - "Don't do anything" - Show a skip button - Skip segment - Stats - "You've saved people from <b>%s</b> segments." - "That's <b>%s</b> of their lives. Click to see the leaderboard" - SponsorBlock is disabled - "You've skipped <b>%s</b> segments." - "That's <b>%s</b>." - Submissions: <b>%s</b> - Your username: <b>%s</b> - Click to change your username - Username successfully changed - Unable to change username: Status: %d %s - "Can't submit the segment. -Already exists" - "Can't submit the segment. - -%s" - - Can\'t submit the segment: %s - "Can't submit the segment. -Rate Limited (Too many from the same user or IP)" - Unable to submit segments: Status: %d %s - Submitting segment… - Segment submitted successfully - Tap to skip - Change category - Downvote - "Can't vote for segment. - -%s" - "Can't vote for segment. -Rate Limited (Too many from the same user or IP)" - Unable to vote for segment: Status: %d %s - There are no segments to vote for - Voting for segment… - Voted successfully - Upvote diff --git a/src/main/resources/youtube/settings/values-v21/strings.xml b/src/main/resources/youtube/settings/values-v21/strings.xml index ce28bac2d..ca1cf7ff8 100644 --- a/src/main/resources/youtube/settings/values-v21/strings.xml +++ b/src/main/resources/youtube/settings/values-v21/strings.xml @@ -46,5 +46,6 @@ materialyou materialyou + amoled - @string/pref_offline_smart_downloads_loading + Sponsor.Ajay.app + @string/pref_offline_smart_downloads_loading diff --git a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_adjust.xml b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_adjust.xml index 89cdd5591..76a4b8bc9 100644 --- a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_adjust.xml +++ b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_adjust.xml @@ -1,5 +1,10 @@ - - - - \ No newline at end of file + + + diff --git a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_compare.xml b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_compare.xml index a682d9fb4..04cc65e40 100644 --- a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_compare.xml +++ b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_compare.xml @@ -1,5 +1,10 @@ - - - - \ No newline at end of file + + + diff --git a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_edit.xml b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_edit.xml index 79ac2d1e5..e93574bd9 100644 --- a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_edit.xml +++ b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_edit.xml @@ -1,5 +1,10 @@ - - - - \ No newline at end of file + + + diff --git a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_logo.xml b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_logo.xml index f350f829f..b6f7d1443 100644 --- a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_logo.xml +++ b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_logo.xml @@ -1,6 +1,13 @@ - - - - - \ No newline at end of file + + + + diff --git a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_voting.xml b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_voting.xml index a88b4a983..d9d9679bd 100644 --- a/src/main/resources/youtube/sponsorblock/drawable/ic_sb_voting.xml +++ b/src/main/resources/youtube/sponsorblock/drawable/ic_sb_voting.xml @@ -1,4 +1,3 @@ - diff --git a/src/main/resources/youtube/sponsorblock/host/layout/youtube_controls_layout.xml b/src/main/resources/youtube/sponsorblock/host/layout/youtube_controls_layout.xml index 48d903b87..612a8fe58 100644 --- a/src/main/resources/youtube/sponsorblock/host/layout/youtube_controls_layout.xml +++ b/src/main/resources/youtube/sponsorblock/host/layout/youtube_controls_layout.xml @@ -1,4 +1,27 @@ - - - + + + + diff --git a/src/main/resources/youtube/sponsorblock/layout/inline_sponsor_overlay.xml b/src/main/resources/youtube/sponsorblock/layout/inline_sponsor_overlay.xml index 6bc670fb9..9f4221735 100644 --- a/src/main/resources/youtube/sponsorblock/layout/inline_sponsor_overlay.xml +++ b/src/main/resources/youtube/sponsorblock/layout/inline_sponsor_overlay.xml @@ -1,5 +1,23 @@ - - + + + + \ No newline at end of file diff --git a/src/main/resources/youtube/sponsorblock/layout/new_segment.xml b/src/main/resources/youtube/sponsorblock/layout/new_segment.xml index 155907c96..be5020be2 100644 --- a/src/main/resources/youtube/sponsorblock/layout/new_segment.xml +++ b/src/main/resources/youtube/sponsorblock/layout/new_segment.xml @@ -3,58 +3,58 @@ xmlns:yt="http://schemas.android.com/apk/res-auto"> + android:layout_height="wrap_content" + android:background="#66000000" + android:gravity="start|center" + android:orientation="vertical"> + android:paddingTop="3.0dip" + android:paddingEnd="5.0dip" + android:paddingBottom="3.0dip" + android:src="@drawable/player_fast_rewind" /> + android:paddingTop="3.0dip" + android:paddingEnd="5.0dip" + android:paddingBottom="3.0dip" + android:src="@drawable/player_fast_forward" /> + android:paddingTop="3.0dip" + android:paddingEnd="10.0dip" + android:paddingBottom="3.0dip" + android:src="@drawable/ic_sb_adjust" /> + android:paddingTop="3.0dip" + android:paddingEnd="5.0dip" + android:paddingBottom="3.0dip" + android:src="@drawable/ic_sb_compare" /> + android:paddingTop="3.0dip" + android:paddingEnd="5.0dip" + android:paddingBottom="3.0dip" + android:src="@drawable/ic_sb_edit" /> + android:paddingTop="3.0dip" + android:paddingEnd="10.0dip" + android:paddingBottom="3.0dip" + android:src="@drawable/ic_sb_publish" /> \ No newline at end of file diff --git a/src/main/resources/youtube/sponsorblock/layout/skip_sponsor_button.xml b/src/main/resources/youtube/sponsorblock/layout/skip_sponsor_button.xml index 3ceb8c362..3a3167bb8 100644 --- a/src/main/resources/youtube/sponsorblock/layout/skip_sponsor_button.xml +++ b/src/main/resources/youtube/sponsorblock/layout/skip_sponsor_button.xml @@ -1,7 +1,36 @@ - - - - + + + + + + + \ No newline at end of file