fix #1419, use the proper cover image at creating shortcuts
This commit is contained in:
parent
35bd124b0b
commit
dac85245ba
1 changed files with 2 additions and 1 deletions
|
@ -357,7 +357,8 @@ class DirectoryAdapter(activity: BaseSimpleActivity, var dirs: ArrayList<Directo
|
||||||
val dir = getFirstSelectedItem() ?: return
|
val dir = getFirstSelectedItem() ?: return
|
||||||
val path = dir.path
|
val path = dir.path
|
||||||
val drawable = resources.getDrawable(R.drawable.shortcut_image).mutate()
|
val drawable = resources.getDrawable(R.drawable.shortcut_image).mutate()
|
||||||
activity.getShortcutImage(dir.tmb, drawable) {
|
val coverThumbnail = config.parseAlbumCovers().firstOrNull { it.tmb == dir.path }?.tmb ?: dir.tmb
|
||||||
|
activity.getShortcutImage(coverThumbnail, drawable) {
|
||||||
val intent = Intent(activity, MediaActivity::class.java)
|
val intent = Intent(activity, MediaActivity::class.java)
|
||||||
intent.action = Intent.ACTION_VIEW
|
intent.action = Intent.ACTION_VIEW
|
||||||
intent.putExtra(DIRECTORY, path)
|
intent.putExtra(DIRECTORY, path)
|
||||||
|
|
Loading…
Reference in a new issue