Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 9c4012b3 authored by Przemyslaw Szczepaniak's avatar Przemyslaw Szczepaniak Committed by Android (Google) Code Review
Browse files

Make TextToSpeech.shutdown() work before init callback.

TextToSpeech.shutdown() never worked properly if was called before receiving
onServiceConnected in connection object. Also, due to recent changes,
TextToSpeech.shutdown() did not work until async task created in
onServiceConnected returned its result to the main thread.

This change makes .shutdown() work in all those cases. To allow that
runAction can now execute code with connection that's not fully setuped
- so we can shutt it down. Also, newly created connection is now hold in
new member variable mConnectingServiceConnection, so it can be closed
before receiving onServiceConnected callback.

Also, I changed name of OnServiceConnectedAsyncTask to
SetupConnectionAsyncTask, I find it more descriptive.

Bug: 8003757
Change-Id: I41d84cfdb8fa28fe44235fb4a9764fa8f3d0643c
parent b3608ad8
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment