commit
8145d7e931
|
@ -145,7 +145,7 @@ dependencies {
|
|||
implementation 'androidx.media:media:1.1.0'
|
||||
implementation 'androidx.preference:preference:1.1.1'
|
||||
implementation 'androidx.recyclerview:recyclerview:1.1.0'
|
||||
implementation 'androidx.viewpager2:viewpager2:1.0.0'
|
||||
implementation 'androidx.viewpager2:viewpager2:1.1.0-alpha01'
|
||||
implementation "androidx.work:work-runtime:$workManagerVersion"
|
||||
implementation 'com.google.android.material:material:1.1.0'
|
||||
|
||||
|
|
|
@ -80,7 +80,7 @@ public class PlaybackControlsDialog extends DialogFragment {
|
|||
|
||||
private void setupUi() {
|
||||
final SeekBar barPlaybackSpeed = dialog.findViewById(R.id.playback_speed);
|
||||
final Button butDecSpeed = dialog.findViewById(R.id.butDecSpeed);
|
||||
final TextView butDecSpeed = dialog.findViewById(R.id.butDecSpeed);
|
||||
butDecSpeed.setOnClickListener(v -> {
|
||||
if (controller != null && controller.canSetPlaybackSpeed()) {
|
||||
barPlaybackSpeed.setProgress(barPlaybackSpeed.getProgress() - 2);
|
||||
|
@ -88,7 +88,7 @@ public class PlaybackControlsDialog extends DialogFragment {
|
|||
VariableSpeedDialog.showGetPluginDialog(getContext());
|
||||
}
|
||||
});
|
||||
final Button butIncSpeed = (Button) dialog.findViewById(R.id.butIncSpeed);
|
||||
final TextView butIncSpeed = dialog.findViewById(R.id.butIncSpeed);
|
||||
butIncSpeed.setOnClickListener(v -> {
|
||||
if (controller != null && controller.canSetPlaybackSpeed()) {
|
||||
barPlaybackSpeed.setProgress(barPlaybackSpeed.getProgress() + 2);
|
||||
|
|
|
@ -143,7 +143,7 @@ public class AudioPlayerFragment extends Fragment implements
|
|||
pageIndicator = root.findViewById(R.id.page_indicator);
|
||||
pageIndicator.setViewPager(pager);
|
||||
pageIndicator.setOnClickListener(v ->
|
||||
pager.setCurrentItem((pager.getCurrentItem() + 1) % pager.getChildCount()));
|
||||
pager.setCurrentItem((pager.getCurrentItem() + 1) % NUM_CONTENT_FRAGMENTS));
|
||||
return root;
|
||||
}
|
||||
|
||||
|
|
|
@ -41,18 +41,22 @@
|
|||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
android:orientation="horizontal"
|
||||
android:gravity="center_vertical">
|
||||
|
||||
<Button
|
||||
<TextView
|
||||
android:id="@+id/butDecSpeed"
|
||||
android:layout_width="32dp"
|
||||
android:layout_height="32dp"
|
||||
android:gravity="center"
|
||||
android:text="-"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:textStyle="bold"
|
||||
android:textColor="?attr/colorAccent"
|
||||
android:textSize="24sp"
|
||||
android:background="?attr/selectableItemBackgroundBorderless" />
|
||||
android:textColor="?attr/colorSecondary"
|
||||
android:contentDescription="@string/decrease_volume"
|
||||
android:background="?attr/selectableItemBackgroundBorderless"/>
|
||||
|
||||
<SeekBar
|
||||
android:id="@+id/playback_speed"
|
||||
|
@ -61,16 +65,18 @@
|
|||
android:max="70"
|
||||
android:layout_weight="1" />
|
||||
|
||||
<Button
|
||||
<TextView
|
||||
android:id="@+id/butIncSpeed"
|
||||
android:layout_width="32dp"
|
||||
android:layout_height="32dp"
|
||||
android:minWidth="0dp"
|
||||
android:gravity="center"
|
||||
android:text="+"
|
||||
android:clickable="true"
|
||||
android:focusable="true"
|
||||
android:textStyle="bold"
|
||||
android:textColor="?attr/colorAccent"
|
||||
android:textSize="24sp"
|
||||
android:textColor="?attr/colorSecondary"
|
||||
android:contentDescription="@string/increase_volume"
|
||||
android:background="?attr/selectableItemBackgroundBorderless" />
|
||||
</LinearLayout>
|
||||
|
||||
|
|
|
@ -50,21 +50,15 @@
|
|||
android:id="@+id/butCancel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?android:attr/selectableItemBackground"
|
||||
android:textColor="?attr/colorAccent"
|
||||
android:paddingLeft="8dp"
|
||||
android:paddingRight="8dp"
|
||||
android:text="@string/cancel_label"/>
|
||||
android:text="@string/cancel_label"
|
||||
style="@style/Widget.MaterialComponents.Button.TextButton"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/butConfirm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?android:attr/selectableItemBackground"
|
||||
android:textColor="?attr/colorAccent"
|
||||
android:paddingLeft="8dp"
|
||||
android:paddingRight="8dp"
|
||||
android:text="@string/confirm_label"/>
|
||||
android:text="@string/confirm_label"
|
||||
style="@style/Widget.MaterialComponents.Button.TextButton"/>
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
|
@ -1,67 +1,39 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" >
|
||||
<RelativeLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/footer"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="48dp"
|
||||
android:layout_alignParentBottom="true" >
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dip"
|
||||
android:layout_alignParentTop="true"
|
||||
android:background="?android:attr/dividerVertical" />
|
||||
|
||||
<View
|
||||
android:id="@+id/horizontal_divider"
|
||||
android:layout_width="1dip"
|
||||
android:layout_height="fill_parent"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginBottom="4dp"
|
||||
android:layout_marginTop="4dp"
|
||||
android:background="?android:attr/dividerVertical" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/butCancel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_alignParentStart="true"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_toLeftOf="@id/horizontal_divider"
|
||||
android:layout_toStartOf="@id/horizontal_divider"
|
||||
android:background="?android:attr/selectableItemBackground"
|
||||
android:textColor="?android:attr/textColorPrimary"
|
||||
android:text="@string/cancel_label" />
|
||||
|
||||
<Button
|
||||
<Button
|
||||
android:id="@+id/butConfirm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_toRightOf="@id/horizontal_divider"
|
||||
android:layout_toEndOf="@id/horizontal_divider"
|
||||
android:background="?android:attr/selectableItemBackground"
|
||||
android:textColor="?android:attr/textColorPrimary"
|
||||
android:text="@string/confirm_label" />
|
||||
</RelativeLayout>
|
||||
style="@style/Widget.MaterialComponents.Button.TextButton"
|
||||
android:layout_margin="8dp"
|
||||
android:text="@string/confirm_label"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/butCancel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_toLeftOf="@+id/butConfirm"
|
||||
android:layout_toStartOf="@+id/butConfirm"
|
||||
style="@style/Widget.MaterialComponents.Button.TextButton"
|
||||
android:layout_margin="8dp"
|
||||
android:text="@string/cancel_label"/>
|
||||
|
||||
<ListView
|
||||
android:id="@+id/feedlist"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_above="@id/footer"
|
||||
android:layout_alignParentTop="true"
|
||||
tools:listitem="@android:layout/simple_list_item_multiple_choice" >
|
||||
android:id="@+id/feedlist"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_above="@id/butConfirm"
|
||||
android:layout_alignParentTop="true"
|
||||
tools:listitem="@android:layout/simple_list_item_multiple_choice">
|
||||
</ListView>
|
||||
|
||||
</RelativeLayout>
|
||||
</RelativeLayout>
|
||||
|
|
|
@ -672,6 +672,8 @@
|
|||
<!-- Content descriptions for image buttons -->
|
||||
<string name="rewind_label">Rewind</string>
|
||||
<string name="fast_forward_label">Fast forward</string>
|
||||
<string name="increase_volume">Increase volume</string>
|
||||
<string name="decrease_volume">Decrease volume</string>
|
||||
<string name="media_type_audio_label">Audio</string>
|
||||
<string name="media_type_video_label">Video</string>
|
||||
<string name="navigate_upwards_label">Navigate upwards</string>
|
||||
|
|
Loading…
Reference in New Issue