[AC-3677] Android: URL Scheme intent is not being placed on AndroidManifest.xml after build
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | n/a |
Status | Closed |
Resolution | Cannot Reproduce |
Resolution Date | 2016-06-14T20:02:58.000+0000 |
Affected Version/s | Appcelerator Studio 4.4.1 |
Fix Version/s | n/a |
Components | Titanium SDK & CLI |
Labels | android, android-6, android-manifest, cli, url-scheme |
Reporter | Caio Perdona |
Assignee | Shak Hossain |
Created | 2016-05-31T21:50:47.000+0000 |
Updated | 2016-06-14T20:02:59.000+0000 |
Description
After inserting code below into my tiapp.xml
<activity android:label="@string/app_name"
android:configChanges="keyboardHidden"
android:name=".PinionActivity"
android:screenOrientation="portrait" android:theme="@style/Theme.NoActionBar"
url="app.js" android:launchMode="singleTask" android:alwaysRetainTaskState="true">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
<intent-filter>
<action android:name="br.com.pinion.MESSAGE"/>
<category android:name="android.intent.category.DEFAULT"/>
</intent-filter>
<intent-filter>
<data android:scheme="pinion"/>
<action android:name="android.intent.action.VIEW"/>
<category android:name="android.intent.category.DEFAULT"/>
<category android:name="android.intent.category.BROWSABLE"/>
</intent-filter>
</activity>
URL schemes fail to launch app. After researching a bit, I found that Titanium is failing to insert the intent-filter into the generated AndroidManifest.xml located on build folder.
After overriding the tiapp.xml (putting generated AndroidManifest on app/platform/android) and manually inserting the code above, it worked like a charm.
Can anyone help me with this issue?
Thanks in advance.
Hello, Please check if the format of your customized manifest in tiapp.xml is correct. Things are working just fine in my environment in this regard. Thanks *Customized manifest in tiapp.xml :*
*Generated AndroidManifest.xml:*
*Environment*: *Device info:* Nexus7 (android 6.0.1) *Node.js Version:* 0.12.7 *npm Version:* 2.11.3 *Titanium SDKs:* 5.2.2.GA *Java Development Kit Version:* 1.8.0_73 *Titanium CLI Version:* 5.0.5 *Appcelerator CLI Version:* 5.2.2 *Appcelerator Studio:* 4.5.0
Hello, If you are having a specific issue using URL scheme in Android here is a fairly easy guide for you to follow. http://fokkezb.nl/2013/08/26/url-schemes-for-ios-and-android-1/. Follow the guide for using URL Scheme in Appcelerator. We are able to build and get the activity node in AndroidManifest.xml, which we then put in tiapp.xml Regards, Sharif
Guys, still no luck. Intent is not being placed on manifest, followed the link above in the first time already. Can't find anything wrong with my tiapp.xml. This is so strange...
Hello, We are not able to regenerate your issue. Perhaps you are not correctly following the instruction in http://fokkezb.nl/2013/08/26/url-schemes-for-ios-and-android-1/. Please share with us how you are performing the action in details, possibly with screenshots or video demonstration. We will be able to escalate the ticket once we establish it's a real bug. Regards, Sharif.