def on_actionPlayScore_toggled(self, onOff): if onOff: if not self._canPlayback(): self.actionPlayScore.toggle() return DBMidi.playScore(self.scoreScene.score) self.musicStart() else: self.musicDone() DBMidi.shutUp()
def on_actionLoopBars_toggled(self, onOff): if onOff: if not self.scoreScene.hasDragSelection(): self.actionLoopBars.toggle() return DBMidi.loopBars(self.scoreScene.iterDragSelection(), self.scoreScene.score) self.musicStart() else: self.musicDone() DBMidi.shutUp()