File tree Expand file tree Collapse file tree 1 file changed +11
-5
lines changed
AnkiDroid/src/main/java/com/ichi2/anki Expand file tree Collapse file tree 1 file changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -453,17 +453,23 @@ abstract class NavigationDrawerActivity :
453453 return
454454 }
455455 // Review Cards Shortcut
456- val intentReviewCards = Reviewer .getIntent(context)
457- intentReviewCards.action = Intent .ACTION_VIEW
458- intentReviewCards.flags = Intent .FLAG_ACTIVITY_CLEAR_TASK
459- intentReviewCards.putExtra(EXTRA_STARTED_WITH_SHORTCUT , true )
456+ val intentReviewCards =
457+ Reviewer .getIntent(context).apply {
458+ action = Intent .ACTION_VIEW
459+ flags = Intent .FLAG_ACTIVITY_CLEAR_TOP
460+ putExtra(EXTRA_STARTED_WITH_SHORTCUT , true )
461+ }
462+ val deckPickerIntent =
463+ Intent (context, IntentHandler ::class .java).apply {
464+ action = Intent .ACTION_VIEW
465+ }
460466 val reviewCardsShortcut =
461467 ShortcutInfoCompat
462468 .Builder (context, " reviewCardsShortcutId" )
463469 .setShortLabel(context.getString(R .string.studyoptions_start))
464470 .setLongLabel(context.getString(R .string.studyoptions_start))
465471 .setIcon(IconCompat .createWithResource(context, R .drawable.review_shortcut))
466- .setIntent( intentReviewCards)
472+ .setIntents(arrayOf(deckPickerIntent, intentReviewCards) )
467473 .build()
468474
469475 // Add Shortcut
You can’t perform that action at this time.
0 commit comments