`MediaPlayer` only seems to have states for playing and paused, but not stopped. Further, playing when the queue is finished seems to restart playback from the beginning.
Here we clear the list of items to play if the player is paused and we're on the last item. We assume we're done with all items to speak, and clear the list before appending a new item and beginning playback again.
The correct solution is probably to investigate how events work in winrt-rs, but callbacks and Rust have always been a disaster when I've tried them, so I'm hesitant. This does seem to handle the basic scenarios I've thrown at it.
* Move autogenerated code to subcrate to speed up compilation.
* `is_speaking` also checks whether a source is opening, in addition to whether it is playing.
* Return to using autoplay.
Two Tolk instances were being created. One checked for the presence of a screen reader. The other actually performed the speech, and was returned as part of the `TTS` instance.
Unfortunately, Tolk doesn't seem to appreciate being called twice. So here we check if a screen reader is detected and, if one is, return the instance that did the detection. Otherwise, error out and return the WinRT backend.
I'd previously attempted to normalize everything to `u8`, but this had some drawbacks:
* It failed to account for some synthesis drivers defining normal as mid-range, while most define it very low.
* It didn't track the normal value for a given synthesizer.
* There was no clean way to map a curve between the minimum, normal, and maximum rates.
Here we track the minimum, normal, and maximum values of rate, pitch, and volume. Sanity checks are done on set.
Also, as a further proof-of-concept, all properties are now implemented for the WinRT driver.