Hey folks, My application (Ghost SEED) makes heavy use of Linkify for an in-app help system. I use a fairly standard setup: I linkify text on an activity displaying help, with the links firing an intent that I filter in the same help activity. In older versions of Android (2.1, 2.2, etc) this works fine. On my HTC One S, which runs 4.0.3, it doesn't work. Linkify does correctly create links, but my activity never gets called with the intent. Does anyone have an idea what might have changed here?
I'm including the appropriate code snippets below: -------- From the manifest --------------------- <activity android:name=".ClientUI.HelpActivity" class="HelpActivity" android:theme="@android:style/Theme.Dialog"> <intent-filter> <category android:name="android.intent.category.DEFAULT"/> <action android:name="android.intent.action.VIEW"/> <data android:scheme="content"/> <data android:host="com.ctenophore.gso.help"/> </intent-filter> </activity> -------- From the code that calls Linkify --------------------- public final static String helpPrefix = "content://com.ctenophore.gso.help/"; ... public static void LinkifyText(TextView text) { ArrayList<String> keywords = GSOHelpItems.titles(); StringBuilder sb = new StringBuilder(); boolean gotOne = false; for (String keyword : keywords) { if (gotOne) sb.append('|'); else gotOne = true; sb.append("\\b"); sb.append(keyword); sb.append("\\b"); } Pattern matcher = Pattern.compile(sb.toString(), Pattern.DOTALL); Linkify.addLinks(text, matcher, helpPrefix); } -------- From the activity --------------------- /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.help); Uri data = getIntent().getData(); if (data == null) { // Do some stuff } else { String url = data.toString(); // Do some stuff with the url --- NOTE: This is never reached in Android 4 } Cheers, Jim Fear is the dark room where the Devil develops his negatives. - Gary Busey -- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en