Skip to content

Commit f68bbc3

Browse files
Carl MillerCarl Miller
authored andcommitted
refactor: Remove 2x speed overlay text from hold-to-fast-forward feature
1 parent d050e8b commit f68bbc3

File tree

4 files changed

+1
-51
lines changed

4 files changed

+1
-51
lines changed

app/src/main/java/org/schabi/newpipe/player/ui/VideoPlayerUi.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -448,10 +448,8 @@ protected void setupElementsSize(final int buttonsMinWidth,
448448

449449
/**
450450
* Called when hold-to-fast-forward is activated (long press detected).
451-
* Shows the visual indicator overlay.
452451
*/
453452
public void onHoldToFastForwardStart() {
454-
animate(binding.holdToFastForwardOverlay, true, DEFAULT_CONTROLS_DURATION);
455453
// Hide controls while fast forwarding
456454
if (isControlsVisible()) {
457455
hideControls(DEFAULT_CONTROLS_DURATION, 0);
@@ -460,10 +458,9 @@ public void onHoldToFastForwardStart() {
460458

461459
/**
462460
* Called when hold-to-fast-forward is deactivated (finger released).
463-
* Hides the visual indicator overlay.
464461
*/
465462
public void onHoldToFastForwardEnd() {
466-
animate(binding.holdToFastForwardOverlay, false, DEFAULT_CONTROLS_DURATION);
463+
// No visual indicator to hide
467464
}
468465
//endregion
469466

app/src/main/res/drawable/ic_fast_forward.xml

Lines changed: 0 additions & 10 deletions
This file was deleted.

app/src/main/res/layout/player.xml

Lines changed: 0 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -791,40 +791,4 @@
791791
android:alpha="0"
792792
android:visibility="invisible" /> <!-- Required for the first appearance fading correctly -->
793793

794-
<!-- Hold to fast forward indicator -->
795-
<LinearLayout
796-
android:id="@+id/holdToFastForwardOverlay"
797-
android:layout_width="wrap_content"
798-
android:layout_height="wrap_content"
799-
android:layout_centerHorizontal="true"
800-
android:layout_marginTop="80dp"
801-
android:background="@drawable/background_oval_black_transparent"
802-
android:gravity="center"
803-
android:orientation="horizontal"
804-
android:paddingStart="20dp"
805-
android:paddingTop="12dp"
806-
android:paddingEnd="20dp"
807-
android:paddingBottom="12dp"
808-
android:visibility="gone"
809-
tools:visibility="visible">
810-
811-
<androidx.appcompat.widget.AppCompatImageView
812-
android:layout_width="24dp"
813-
android:layout_height="24dp"
814-
android:layout_marginEnd="8dp"
815-
android:src="@drawable/ic_fast_forward"
816-
app:tint="@color/white"
817-
tools:ignore="ContentDescription" />
818-
819-
<org.schabi.newpipe.views.NewPipeTextView
820-
android:id="@+id/holdToFastForwardText"
821-
android:layout_width="wrap_content"
822-
android:layout_height="wrap_content"
823-
android:text="@string/hold_to_fast_forward_indicator"
824-
android:textColor="@android:color/white"
825-
android:textSize="16sp"
826-
android:textStyle="bold" />
827-
828-
</LinearLayout>
829-
830794
</RelativeLayout>

app/src/main/res/values/strings.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@
9393
<string name="ignore_hardware_media_buttons_summary">Useful, for instance, if you are using a headset with broken physical buttons</string>
9494
<string name="hold_to_fast_forward_title">Hold to fast forward</string>
9595
<string name="hold_to_fast_forward_summary">Tap and hold on the video to play at 2x speed while held</string>
96-
<string name="hold_to_fast_forward_indicator">2x Speed</string>
9796
<string name="show_comments_title">Show comments</string>
9897
<string name="show_comments_summary">Turn off to hide comments</string>
9998
<string name="show_next_and_similar_title">Show \'Next\' and \'Similar\' videos</string>

0 commit comments

Comments
 (0)