mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-11-19 22:29:15 +01:00
Clean up track button changes
This commit is contained in:
parent
c666dd623d
commit
925f71af15
@ -66,9 +66,8 @@ class TrackSearchDialog : DialogController {
|
|||||||
binding!!.toolbar.setNavigationOnClickListener { dialog?.dismiss() }
|
binding!!.toolbar.setNavigationOnClickListener { dialog?.dismiss() }
|
||||||
binding!!.trackBtn.setOnClickListener {
|
binding!!.trackBtn.setOnClickListener {
|
||||||
val adapter = adapter ?: return@setOnClickListener
|
val adapter = adapter ?: return@setOnClickListener
|
||||||
val item = adapter.items.getOrNull(adapter.selectedItemPosition)
|
adapter.items.getOrNull(adapter.selectedItemPosition)?.let {
|
||||||
if (item != null) {
|
trackController.presenter.registerTracking(it, service)
|
||||||
trackController.presenter.registerTracking(item, service)
|
|
||||||
dialog?.dismiss()
|
dialog?.dismiss()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -85,12 +85,16 @@
|
|||||||
|
|
||||||
</FrameLayout>
|
</FrameLayout>
|
||||||
|
|
||||||
|
<com.google.android.material.divider.MaterialDivider
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content" />
|
||||||
|
|
||||||
<Button
|
<Button
|
||||||
android:id="@+id/track_btn"
|
android:id="@+id/track_btn"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginHorizontal="16dp"
|
android:layout_marginHorizontal="16dp"
|
||||||
android:layout_marginVertical="4dp"
|
android:layout_marginVertical="8dp"
|
||||||
android:text="@string/action_track"
|
android:text="@string/action_track"
|
||||||
android:enabled="false" />
|
android:enabled="false" />
|
||||||
|
|
||||||
|
@ -1,12 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
|
||||||
<menu xmlns:android="http://schemas.android.com/apk/res/android"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto">
|
|
||||||
|
|
||||||
<item
|
|
||||||
android:id="@+id/done"
|
|
||||||
android:enabled="false"
|
|
||||||
android:icon="@drawable/ic_check_24dp"
|
|
||||||
android:title="@android:string/ok"
|
|
||||||
app:iconTint="?attr/colorOnToolbar"
|
|
||||||
app:showAsAction="ifRoom" />
|
|
||||||
</menu>
|
|
Loading…
Reference in New Issue
Block a user