I have an unclaimed bounty for this question. If someone is able to provide a working answer that meets my criteria, I will reward them with the bounty. It’s not visible because the bounty expired, but I can reward it after the fact to an acceptable answer.
My app has intent filters set up that work as desired when I use Chrome. Unfortunately, Firefox does not implement deep links the same way. When I tap a link in Firefox, it shows a little Android icon at the end of the address bar. If I tap that, it will open my app in Firefox and I don't like this behavior. With Chrome, it simply opens the app (after prompting you to choose the app the first time)
UPDATE: singletask does not work and it has the heinous side effect of the resuming activity not being able to get the extras from the intent that launched it.
This is not a duplicate of other deep link Firefox questions (this, this, this, this, this, this, and this) because those questions are about how to get deep links to work at all whereas I understand how deep links work in Firefox and they already work for me, but I want to change the behavior...
I'm asking: How, if possible, can I open the existing instance of my app via deep link from Firefox and have it behave the same way that it does with Chrome? I don't want use an iframe.
I have implemented http and https intent filters, like so:
<!-- https -->
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:host="myappurl"
android:pathPrefix="/myprefix"
android:scheme="https" />
</intent-filter>
<!-- http -->
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:host="myappurl"
android:pathPrefix="/myprefix"
android:scheme="http" />
</intent-filter>
If you're going to provide a solution, please provide a clear example that includes context as to where the code should go in the manifest (if at all), and what the side effects are (see my link above- singletask does not work for this)