jwdj / EasyABC

EasyABC
GNU General Public License v2.0
90 stars 36 forks source link

fix MIDI input with latest wx and Python 3 #18

Closed marcstober closed 4 years ago

marcstober commented 4 years ago

This is my latest attempt to get MIDI input working in EasyABC (on Windows 10). When I ran from source code I got this error:

File` ".\easy_abc.py", line 1796, in __init__
        self.tick1 = wx.Sound(os.path.join(cwd, 'sound', 'tick1.wav'))
    AttributeError: module 'wx' has no attribute 'Sound'

It looks like the wx framework the wx.Sound module was moved to wx.adv.Sound.

I also got an error about the Python translate function, which needed a change to work with Python 3.

(I don't know if there are people who need to be able to run EasyABC with older versions of wx or Python, and whether these fixed would break things for them.)

Finally there are two sound files (tick1.wav and tick2.wav) that are used to make a metronome, these weren't included in the sources but I was able to copy them over from an installed version of EasyABC.

The pull request has the 2 code changes; I didn't include the wav files.

jwdj commented 4 years ago

Your modifications have been merged. Thank you marcstober for this fix.