Hacker News new | ask | show | jobs
by anabab 19 days ago
Presumably apps can plug in entries in the system wide context menu? E.g. I have an Anki menu item (not talking about app selection screen to share content!) when selecting text in Firefox
2 comments

Yep, via ACTION_PROCESS_TEXT - this also allows you to show a UI and modify/replace the selected text.

Source: I wrote that AnkiDroid code ~6 years ago.

https://developer.android.com/reference/android/content/Inte...

PS: the menu can be disabled in the "General" settings of AnkiDroid... I need to get around to better onboarding for it.

That doesn't work if the reading app has its own custom context menu (e.g. Google Play Books app)