355 itm = category.child(index) |
355 itm = category.child(index) |
356 txt = itm.data(0, self.objectNameRole) |
356 txt = itm.data(0, self.objectNameRole) |
357 for act in actions: |
357 for act in actions: |
358 if txt == act.objectName(): |
358 if txt == act.objectName(): |
359 act.setShortcut(QKeySequence(itm.text(1))) |
359 act.setShortcut(QKeySequence(itm.text(1))) |
360 act.setAlternateShortcut(QKeySequence(itm.text(2))) |
360 act.setAlternateShortcut(QKeySequence(itm.text(2)), removeEmpty=True) |
361 break |
361 break |
362 |
362 |
363 def on_buttonBox_accepted(self): |
363 def on_buttonBox_accepted(self): |
364 """ |
364 """ |
365 Private slot to handle the OK button press. |
365 Private slot to handle the OK button press. |