mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-11-10 15:57:47 +01:00
Clean up track button changes
This commit is contained in:
parent
c666dd623d
commit
925f71af15
3 changed files with 7 additions and 16 deletions
|
@ -66,9 +66,8 @@ class TrackSearchDialog : DialogController {
|
|||
binding!!.toolbar.setNavigationOnClickListener { dialog?.dismiss() }
|
||||
binding!!.trackBtn.setOnClickListener {
|
||||
val adapter = adapter ?: return@setOnClickListener
|
||||
val item = adapter.items.getOrNull(adapter.selectedItemPosition)
|
||||
if (item != null) {
|
||||
trackController.presenter.registerTracking(item, service)
|
||||
adapter.items.getOrNull(adapter.selectedItemPosition)?.let {
|
||||
trackController.presenter.registerTracking(it, service)
|
||||
dialog?.dismiss()
|
||||
}
|
||||
}
|
||||
|
|
|
@ -85,12 +85,16 @@
|
|||
|
||||
</FrameLayout>
|
||||
|
||||
<com.google.android.material.divider.MaterialDivider
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/track_btn"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginHorizontal="16dp"
|
||||
android:layout_marginVertical="4dp"
|
||||
android:layout_marginVertical="8dp"
|
||||
android:text="@string/action_track"
|
||||
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 a new issue