fix: increased button's tap area to facilitate easier clicking

This commit is contained in:
antonio 2023-11-26 19:28:21 +01:00
parent dfc246d079
commit 612c05fabc
2 changed files with 6 additions and 3 deletions

View file

@ -56,6 +56,7 @@ public class PlayerControllerFragment extends Fragment {
private Chip playerMediaExtension;
private TextView playerMediaBitrate;
private ConstraintLayout playerQuickActionView;
private ImageButton playerOpenQueueButton;
private ImageButton playerTrackInfo;
private MainActivity activity;
@ -109,13 +110,14 @@ public class PlayerControllerFragment extends Fragment {
playerMediaExtension = bind.getRoot().findViewById(R.id.player_media_extension);
playerMediaBitrate = bind.getRoot().findViewById(R.id.player_media_bitrate);
playerQuickActionView = bind.getRoot().findViewById(R.id.player_quick_action_view);
playerOpenQueueButton = bind.getRoot().findViewById(R.id.player_open_queue_button);
playerTrackInfo = bind.getRoot().findViewById(R.id.player_info_track);
}
private void initQuickActionView() {
playerQuickActionView.setBackgroundColor(SurfaceColors.getColorForElevation(requireContext(), 8));
playerQuickActionView.setOnClickListener(view -> {
playerOpenQueueButton.setOnClickListener(view -> {
PlayerBottomSheetFragment playerBottomSheetFragment = (PlayerBottomSheetFragment) requireActivity().getSupportFragmentManager().findFragmentByTag("PlayerBottomSheet");
if (playerBottomSheetFragment != null) {
playerBottomSheetFragment.goToQueuePage();

View file

@ -344,8 +344,9 @@
<ImageButton
android:id="@+id/player_open_queue_button"
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:padding="16dp"
android:background="?attr/selectableItemBackgroundBorderless"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"