How do they do that?
By examining the TtsEngine
sample app in the SDK, it would appear that the process is:
Step #1: Implement a TTS service. Developers who attempt to use this facility to hook arbitrary other stuff into Settings will be shot on sight.
Step #2: In the manifest entry for that service, have a <meta-data>
element with android:name="android.speech.tts"
and an android:resource
attribute pointing to an XML resource.
Step #3: Create the aforementioned XML resource, akin to the following:
<tts-engine xmlns:android="http://schemas.android.com/apk/res/android"
android:settingsActivity="your.settings.activity.GoesHere" />
Alas, this appears to be undocumented. Leastways, I'm not finding any references to this stuff when I search the online developer guide.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…