[View] [Edit] [Lock] [References] [Attachments] [History] [Home] [Changes] [Search] [Help]
sample[jx8-android] TextToSpeech
Expression to run this page |
SwikiCodeRobot @> #JX8AndroidTextToSpeech |
" Text to speech test. "
| tts listener cls |
cls := Point.
listener := Java
newProxy: 'android.speech.tts.TextToSpeech$OnInitListener'
functions: #onInit -> [:status|
status isNil ifTrue: [ self print: 'ERROR: Argument (status) missing' ].
"self print: 'tts status=' ,status."
tts
flush: cls name,' first selector';
add: cls selectors first toString
].
tts := TextToSpeech
context: MainActivity singleton
listener: listener.