Questions tagged [uiapplicationshortcutitem]

Use this tag for questions related to UIApplicationShortcutItem, an application shortcut item, also called a Home screen dynamic quick action, specifies a user-initiated action for your app.

Quoting the ref page:

On a device that supports 3D Touch, a user invokes the quick action by pressing your app's icon on the Home screen and then selecting the quick action’s title. Your app delegate receives and handles the quick action.

and/or are usually found along with this tag, so you might as well consider using them.

40 questions
32
votes
2 answers

How do I specify a custom icon for a static UIApplicationShortcutItem in my iOS 9 App?

I'm currently implementing home screen Quick Actions for my iOS 9 app using 3D Touch. I have several actions using the existing System icons from the defined UIApplicationShortcutIconType enum. An Example:
Chris Allwein
  • 2,498
  • 1
  • 20
  • 24
21
votes
3 answers

Use SF Symbols system image for static UIApplicationShortcutItem

When specifying home screen quick actions, UIApplicationShortcutItems, in your Info.plist, is there a way to use a system image from SF Symbols? The docs noting the available iOS keys doesn't specify a key to do this, besides specifying one of the…
Jordan H
  • 52,571
  • 37
  • 201
  • 351
11
votes
1 answer

Share App application shortcut [UIApplicationShortcutIconTypeShare]

I've seen a lot of apps use the UIApplicationShortcutIconTypeShare application shortcut to share their app right from the home screen. It launches a UIActivityViewController right from the home screen without opening the app. How do you do that?
8
votes
3 answers

UIImage from UIApplicationShortcutIcon

There are some great "Quick Action Icons" available at https://developer.apple.com/ios/human-interface-guidelines/graphics/system-icons/. Is it possible to make a UIImage from one of these UIApplicationShortcutIcons to use on, say, a UIButton. For…
ajrlewis
  • 2,968
  • 3
  • 33
  • 67
3
votes
1 answer

How to add more than 4 quick action items in UIApplicationShortcutIcons(3D touch) in iOS Application

I am working on 3D touch features in iOS. I want to add more than 4 shortcut items. I go through apple documentation which states that iOS 9 displays up to four Home screen quick actions for your app But the soundhound application is showing 5…
Sahil Mahajan
  • 3,922
  • 2
  • 29
  • 43
3
votes
2 answers

AppDelegate function for UIApplicationShortcutItem not being called in Swift 3 / Xcode 8 beta 6

The Swift 3 converter changed this (perfectly functioning) line: func application(application: UIApplication, performActionForShortcutItem shortcutItem: UIApplicationShortcutItem, completionHandler: (Bool) -> Void) { to this: func application(_…
2
votes
0 answers

Dynamic UIApplicationShortcutItems reseting when iOS Language Preferences are changed

My app is using dynamic UIApplicationShortcutItems, allowing the user to choose their own custom shortcuts. When the OS language preference is changed, this list is being reset, removing all of the shortcuts and requiring the user to recreate their…
kbrady
  • 81
  • 4
2
votes
1 answer

Update UIApplicationShortcutItem from extension

I am building a Today Extension to an app, and it works great to modify my application data. But now my dynamic UIApplicationShortcutItems are out of sync. I can't access UIApplication.shared from my extension. Is there a way to ask the app to…
Henrik
  • 3,908
  • 27
  • 48
2
votes
1 answer

Navigating to a ViewController from AppDelegate triggered by UIApplicationShortcutItem

In my application, the first view that is launched is controlled by RootUIViewController. Now the user can tap on any of the buttons on this view and then segue to a view controlled by LeafUIViewController. Each button points to this same view, with…
rgamber
  • 5,749
  • 10
  • 55
  • 99
2
votes
1 answer

how to control UIApplicationShortcutItems title & icon location

How can control this? I have try to change the location in the plist.
pathfinder
  • 61
  • 1
  • 6
1
vote
0 answers

iOS 16 Swift App Intents - Phrases Not Working as Expected

I have defined custom App Intents using the new App Intent framework provided in iOS 16. However, not all of these phrases seem to work for Siri. Sometimes it will open another app or will perform a completely different action. Is there a different…
1
vote
0 answers

How would one open an iMessage app extension from the hosting application?

I'm trying to open an iMessage extension application from the main hosting extension using URL in the following manner, if UIApplication.shared.canOpenURL(url){ UIApplication.shared.open(url) }else{ print("unable to open URL") } I added the url…
1
vote
2 answers

Problem using windows path having space in it

I have created a VB script that I am calling from my batch file on Windows 10. The script is something like this: Set startupShortcut = sh.CreateShortcut("%ProgramData%\Microsoft\Windows\Start…
1
vote
1 answer

Is there a way to not open the splash screen/app when launching a shortcut action in iOS?

func application(_ application: UIApplication, performActionFor shortcutItem: UIApplicationShortcutItem, completionHandler: @escaping (Bool) -> Void) { if shortcutItem.type == "com.xyz.test.tests.firstAction" { …
1
vote
1 answer

How to copy to the UIPasteBoard from the Quick Actions menu without entering the app?

Is it possible to directly copy a value from a shortcut item without entering the app? I want to do something similar to Apple's Calculator App:
1
2 3