midi_import.py 文件源码

python
阅读 34 收藏 0 点赞 0 评论 0

项目:Bigglesworth 作者: MaurizioB 项目源码 文件源码
def dump_single(self):
        checked = self.destination_group.checkedId()
        if checked == 0:
            bank = 0x7f
            prog = 0
        elif checked == 1:
            bank = 0x7f
            prog = self.multi_spin.value() - 1
        else:
            bank = self.bank_combo.currentIndex()
            prog = self.prog_spin.value() - 1
            res = QtGui.QMessageBox.question(self, 'Dump selected sound',
                                             'You are going to send a sound dump to the Blofeld at location "{}{:03}".\nThis action cannot be undone. Do you want to proceed?'.format(uppercase[bank], prog+1), 
                                             QtGui.QMessageBox.Ok|QtGui.QMessageBox.Cancel
                                             )
            if not res == QtGui.QMessageBox.Ok: return
        row = self.sounds_table.selectedIndexes()[0].row()
        copy = self.sound_list[row].copy()
        copy.bank = bank
        copy.prog = prog
        self.dump_send.emit(copy)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号