Fix for T1754
AbandonedPublic

Authored by sandroandrade on Mar 11 2016, 10:43 AM.

Details

Reviewers
itsback
Summary

This simply stops anything which is being played by MidiSequencer, before playing the exercise.

With this, pressing the "play question" button in exercise view starts playing the exercise from beginning. Previously "play question" button did nothing if an exercise was being played.

Diff Detail

Repository
R163 Minuet
Lint
Lint Skipped
Unit
Unit Tests Skipped
itsback updated this revision to Diff 2700.Mar 11 2016, 10:43 AM
itsback retitled this revision from to Fix for T1754.
itsback updated this object.
itsback edited the test plan for this revision. (Show Details)
itsback added a reviewer: sandroandrade.
itsback set the repository for this revision to R163 Minuet.
itsback added a project: Minuet.
itsback added a subscriber: itsback.
sandroandrade accepted this revision.Mar 15 2016, 2:48 AM
sandroandrade edited edge metadata.

Ship it!

This revision is now accepted and ready to land.Mar 15 2016, 2:48 AM
sandroandrade requested changes to this revision.Mar 16 2016, 5:38 PM
sandroandrade edited edge metadata.

Hi,

This is actually wrong, because you should interrupt the output thread first and wait for its termination. Otherwise, you get occasional crashes.

This revision now requires changes to proceed.Mar 16 2016, 5:38 PM

But the output thread is stopped by m_midiSequencer->stop(); as it calls m_midiSequencerOutputThread->stop();
And m_midiSequencerOutputThread->stop() is defined in Drumstick so we can assume that they are safely closing the thread.

I'm abandoning that by now, since we postponed MIDI files playing features to v0.2 or v0.3.
Thanks for sending the patch.

sandroandrade commandeered this revision.May 26 2016, 6:20 PM
sandroandrade abandoned this revision.
sandroandrade edited reviewers, added: itsback; removed: sandroandrade.