mirror of
https://github.com/tachiyomiorg/tachiyomi.git
synced 2024-11-05 01:15:14 +01:00
Add confirm dialog for multiple deletion. Closes #155
This commit is contained in:
parent
a0f7761a37
commit
7f5879ed6f
@ -282,7 +282,14 @@ class ChaptersFragment : BaseRxFragment<ChaptersPresenter>(), ActionMode.Callbac
|
||||
R.id.action_mark_as_read -> markAsRead(getSelectedChapters())
|
||||
R.id.action_mark_as_unread -> markAsUnread(getSelectedChapters())
|
||||
R.id.action_download -> downloadChapters(getSelectedChapters())
|
||||
R.id.action_delete -> deleteChapters(getSelectedChapters())
|
||||
R.id.action_delete -> {
|
||||
MaterialDialog.Builder(activity)
|
||||
.content(R.string.confirm_delete_chapters)
|
||||
.positiveText(android.R.string.yes)
|
||||
.negativeText(android.R.string.no)
|
||||
.onPositive { dialog, action -> deleteChapters(getSelectedChapters()) }
|
||||
.show()
|
||||
}
|
||||
else -> return false
|
||||
}
|
||||
return true
|
||||
|
@ -228,6 +228,7 @@
|
||||
<string name="download_10">Download next 10 chapters</string>
|
||||
<string name="download_all">Download all</string>
|
||||
<string name="download_unread">Download unread</string>
|
||||
<string name="confirm_delete_chapters">Are you sure you want to delete selected chapters?</string>
|
||||
|
||||
<!-- MyAnimeList fragment -->
|
||||
<string name="reading">Reading</string>
|
||||
|
Loading…
Reference in New Issue
Block a user