Titanium.UI.iOS.ShortcutParams
Object of options for Titanium.UI.iOS.ApplicationShortcuts.addDynamicShortcut.
The parameters used when creating and receiving a shortcut. When used for creation, it must include at least the identifier and title properties.
Since: 5.1.0 · Platforms: iphone
Properties #
icon#
Type: Number, String, Titanium.Contacts.Person
The icon to be displayed on the application shortcut. You can either use one of the constants like
Titanium.UI.iOS.SHORTCUT_ICON_TYPE_COMPOSE, a local image specified by the image path or a reference to a
Titanium.Contacts.Person.
If you are using one of the pre-defined constants, you can reference to the list of icons from Apple here.
If you are using an image file, enable slicing (adding the image to an asset catalog) for
the project. To enable slicing, add the use-app-thinning element to the ios element in the
tiapp.xml file and set the value to true. If you do not enable slicing, the image will
not be displayed.
<ti:app>
<ios>
<use-app-thinning>true</use-app-thinning>
</ios>
</ti:app>
The recommended size for image files is 35dp (@2px: 70dp, @3x: 105dp). Also check the Apple documentation
for more information on shortcut icons.
On iOS 13 and higher, with SDK 8.2.1 or higher, you can pass in the Ti.Blob instance returned from <Ti.UI.iOS.systemImage>.
identifier#
Type: String
The unique key for the application shortcut. Equates to the underlying UIApplicationShortcutItemIconType key
subtitle#
Type: String
The subtitle displayed on the application shortcut.
The subtitle can be localized, see here
for more infos.
title#
Type: String
The title of the application shortcut.
The title can be localized, see here
for more infos.
userInfo#
Type: Object
The userInfo of the application shortcut.
The userInfo is an object containing information about the shortcut like an ID or details about it.