diff options
author | Mike Fulbright <msf@redhat.com> | 2001-07-13 22:34:52 +0000 |
---|---|---|
committer | Mike Fulbright <msf@redhat.com> | 2001-07-13 22:34:52 +0000 |
commit | f1c56380b4d0607648dfce2bfe780d7226de45cc (patch) | |
tree | 43f86208a551ce952c5729f37b795308610d6b90 /iw | |
parent | db838fe23afd468ceb20bf012bcdac0c920e8262 (diff) | |
download | anaconda-f1c56380b4d0607648dfce2bfe780d7226de45cc.tar.gz anaconda-f1c56380b4d0607648dfce2bfe780d7226de45cc.tar.xz anaconda-f1c56380b4d0607648dfce2bfe780d7226de45cc.zip |
tried to wire up accelerator keys, not quite working yet
Diffstat (limited to 'iw')
-rw-r--r-- | iw/partition_gui.py | 20 |
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) |