Details
-
Type:
Bug
-
Status: Closed
-
Priority:
Critical
-
Resolution: Fixed
-
Affects Version/s: None
-
Fix Version/s: Release 6.0.0, Release 5.4.0
-
Component/s: iOS
-
Story Points:5
-
Sprint:2016 Sprint 13 SDK
Description
I am testing out the new support for Application Shortcuts as described here:
http://www.appcelerator.com/blog/2015/11/ios-9-3d-touch-sample-app/
I have the shortcuts showing when I press on the app icon - perfect.
However as soon as the app launches it crashes. And the reason is that when the app is launched or resumed I perform some checks for incoming parameters using the Ti.App.getArguments().
And it seems that whenever the app is launched using a App Shortcut, then any subsequent call to Ti.App.getArguments() crashes the app.
The crash error message is:
[UIApplicationShortcutItem boundBridge:withKrollObject:]: unrecognized selector sent to instance 0x137d65370
|
I will attach a sample project which has a App Shortcut set in the tiapp.xml file as follows:
<key>UIApplicationShortcutItems</key> |
<array> |
<dict> |
<key>UIApplicationShortcutItemIconType</key> |
<string>UIApplicationShortcutIconTypeSearch</string> |
<key>UIApplicationShortcutItemTitle</key> |
<string>Search</string> |
<key>UIApplicationShortcutItemType</key> |
<string>search</string> |
<key>UIApplicationShortcutItemUserInfo</key> |
<dict/> |
</dict> |
</array> |
And a very simple app.js using native code:
var win = Ti.UI.createWindow({ |
backgroundColor: 'blue' |
});
|
win.open();
|
|
Ti.App.getArguments();
|
Make sure the app is force closed. Then launch the app via the App Shortcut (not the app icon). It will crash with the above error.
Tested on my iPhone 6S Plus.