summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--iw/partition_gui.py20
1 files changed, 14 insertions, 6 deletions
diff --git a/iw/partition_gui.py b/iw/partition_gui.py
index 58ae20c6b..3d404c17e 100644
--- a/iw/partition_gui.py
+++ b/iw/partition_gui.py
@@ -1301,13 +1301,21 @@ class PartitionWindow(InstallWindow):
buttonBox = GtkHButtonBox()
buttonBox.set_layout (BUTTONBOX_SPREAD)
- ops = ((_("New"), self.newCB),
- (_("Edit"), self.editCb),
- (_("Delete"), self.deleteCb),
- (_("Reset"), self.resetCb),
- (_("Make Raid"), self.makeraidCB))
+ self.accelgroup = GtkAccelGroup()
+
+ ops = ((_("_New"), self.newCB),
+ (_("_Edit"), self.editCb),
+ (_("_Delete"), self.deleteCb),
+ (_("_Reset"), self.resetCb),
+ (_("Make _Raid"), self.makeraidCB))
+
for label, cb in ops:
- button = GtkButton (label)
+ labelwid = GtkLabel(label)
+ key = labelwid.parse_uline(label)
+ button = GtkButton ()
+ button.add(labelwid)
+ button.add_accelerator("clicked", self.accelgroup, key,
+ GDK.MOD1_MASK, 0)
buttonBox.add (button)
button.connect ("clicked", cb)