(txt)
| 62 | return buildMenuBar(parent, datas, menuBar) |
| 63 | |
| 64 | def codeSplit(txt): |
| 65 | sep = txt.split('-') |
| 66 | acc, code = wx.ACCEL_NORMAL, -1 |
| 67 | if 'Ctrl' in sep: acc|= wx.ACCEL_CTRL |
| 68 | if 'Alt' in sep: acc|= wx.ACCEL_ALT |
| 69 | if 'Shift' in sep: acc|= wx.ACCEL_SHIFT |
| 70 | fs = ['F{}'.format(i) for i in range(1,13)] |
| 71 | if sep[-1] in fs: |
| 72 | code = 340+fs.index(sep[-1]) |
| 73 | elif len(sep[-1])==1: code = ord(sep[-1]) |
| 74 | return acc, code |
| 75 | |
| 76 | def buildShortcut(parent): |
| 77 | shortcuts = [] |