mirror of
https://github.com/TeamNewPipe/NewPipe
synced 2024-12-23 16:40:32 +00:00
Fix fast seek overlay arc not correctly centered
This happened in fullscreen player: while play-pause, brightness, volume, ... buttons were correctly centered in the app UI, the fast seek overlay was centered in the system UI, causing a mismatch between the two that looked ugly
This commit is contained in:
parent
54f0b3d8b3
commit
00767f4bf3
@ -572,14 +572,20 @@ public final class Player implements
|
|||||||
});
|
});
|
||||||
|
|
||||||
// PlaybackControlRoot already consumed window insets but we should pass them to
|
// PlaybackControlRoot already consumed window insets but we should pass them to
|
||||||
// player_overlays too. Without it they will be off-centered
|
// player_overlays and fast_seek_overlay too. Without it they will be off-centered.
|
||||||
binding.playbackControlRoot.addOnLayoutChangeListener(
|
binding.playbackControlRoot.addOnLayoutChangeListener(
|
||||||
(v, left, top, right, bottom, oldLeft, oldTop, oldRight, oldBottom) ->
|
(v, left, top, right, bottom, oldLeft, oldTop, oldRight, oldBottom) -> {
|
||||||
binding.playerOverlays.setPadding(
|
binding.playerOverlays.setPadding(
|
||||||
v.getPaddingLeft(),
|
v.getPaddingLeft(),
|
||||||
v.getPaddingTop(),
|
v.getPaddingTop(),
|
||||||
v.getPaddingRight(),
|
v.getPaddingRight(),
|
||||||
v.getPaddingBottom()));
|
v.getPaddingBottom());
|
||||||
|
binding.fastSeekOverlay.setPadding(
|
||||||
|
v.getPaddingLeft(),
|
||||||
|
v.getPaddingTop(),
|
||||||
|
v.getPaddingRight(),
|
||||||
|
v.getPaddingBottom());
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user