From patchwork Mon Jun 8 04:01:53 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lucas Meneghel Rodrigues X-Patchwork-Id: 28549 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n5842JLb007595 for ; Mon, 8 Jun 2009 04:02:20 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750875AbZFHECO (ORCPT ); Mon, 8 Jun 2009 00:02:14 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1750911AbZFHECO (ORCPT ); Mon, 8 Jun 2009 00:02:14 -0400 Received: from mx2.redhat.com ([66.187.237.31]:59282 "EHLO mx2.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750853AbZFHECJ (ORCPT ); Mon, 8 Jun 2009 00:02:09 -0400 Received: from int-mx2.corp.redhat.com (int-mx2.corp.redhat.com [172.16.27.26]) by mx2.redhat.com (8.13.8/8.13.8) with ESMTP id n5842CGP027392 for ; Mon, 8 Jun 2009 00:02:12 -0400 Received: from ns3.rdu.redhat.com (ns3.rdu.redhat.com [10.11.255.199]) by int-mx2.corp.redhat.com (8.13.1/8.13.1) with ESMTP id n5842BnM009445; Mon, 8 Jun 2009 00:02:11 -0400 Received: from localhost.localdomain (vpn-10-45.bos.redhat.com [10.16.10.45]) by ns3.rdu.redhat.com (8.13.8/8.13.8) with ESMTP id n5841xtd011888; Mon, 8 Jun 2009 00:02:10 -0400 From: Lucas Meneghel Rodrigues To: kvm@vger.kernel.org Cc: Lucas Meneghel Rodrigues , Michael Goldish Subject: [KVM-AUTOTEST PATCH 5/8] stepeditor.py: get rid of some shortcuts Date: Mon, 8 Jun 2009 01:01:53 -0300 Message-Id: <1244433717-3391-9-git-send-email-lmr@redhat.com> In-Reply-To: <1244433717-3391-8-git-send-email-lmr@redhat.com> References: <1244433717-3391-1-git-send-email-lmr@redhat.com> <1244433717-3391-2-git-send-email-lmr@redhat.com> <1244433717-3391-3-git-send-email-lmr@redhat.com> <1244433717-3391-4-git-send-email-lmr@redhat.com> <1244433717-3391-5-git-send-email-lmr@redhat.com> <1244433717-3391-6-git-send-email-lmr@redhat.com> <1244433717-3391-7-git-send-email-lmr@redhat.com> <1244433717-3391-8-git-send-email-lmr@redhat.com> X-Scanned-By: MIMEDefang 2.58 on 172.16.27.26 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org Disable a few keyboard shortcuts that were initially assumed to be useful, but apparently override the default functionality of the involved keys (e.g. 'home', 'end', 'delete') regardless of the widget that has the keyboard focus. Also make some indentation changes to the UI description. Signed-off-by: Michael Goldish --- client/tests/kvm/stepeditor.py | 63 +++++++++++++++++++--------------------- 1 files changed, 30 insertions(+), 33 deletions(-) diff --git a/client/tests/kvm/stepeditor.py b/client/tests/kvm/stepeditor.py index f2ef1aa..9669200 100755 --- a/client/tests/kvm/stepeditor.py +++ b/client/tests/kvm/stepeditor.py @@ -858,27 +858,27 @@ class StepMakerWindow: class StepEditor(StepMakerWindow): ui = ''' - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + - ''' +''' # Constructor @@ -896,7 +896,7 @@ class StepEditor(StepMakerWindow): self.window.add_accel_group(accelgroup) # Create an ActionGroup - actiongroup = gtk.ActionGroup('UIManagerExample') + actiongroup = gtk.ActionGroup('StepEditor') # Create actions actiongroup.add_actions([ @@ -904,22 +904,22 @@ class StepEditor(StepMakerWindow): self.quit), ('Open', gtk.STOCK_OPEN, '_Open', None, 'Open steps file', self.open_steps_file), - ('CopyStep', gtk.STOCK_COPY, '_Copy current step...', None, + ('CopyStep', gtk.STOCK_COPY, '_Copy current step...', "", 'Copy current step to user specified position', self.copy_step), - ('DeleteStep', gtk.STOCK_DELETE, '_Delete current step', None, + ('DeleteStep', gtk.STOCK_DELETE, '_Delete current step', "", 'Delete current step', self.event_remove_clicked), - ('InsertNewBefore', gtk.STOCK_ADD, '_New step before current', None, + ('InsertNewBefore', gtk.STOCK_ADD, '_New step before current', "", 'Insert new step before current step', self.insert_before), - ('InsertNewAfter', gtk.STOCK_ADD, 'N_ew step after current', None, + ('InsertNewAfter', gtk.STOCK_ADD, 'N_ew step after current', "", 'Insert new step after current step', self.insert_after), ('InsertStepsBefore', gtk.STOCK_ADD, '_Steps before current...', - None, 'Insert steps (from file) before current step', + "", 'Insert steps (from file) before current step', self.insert_steps_before), - ('InsertStepsAfter', gtk.STOCK_ADD, 'Steps _after current...', - None, 'Insert steps (from file) after current step', + ('InsertStepsAfter', gtk.STOCK_ADD, 'Steps _after current...', "", + 'Insert steps (from file) after current step', self.insert_steps_after), - ('CleanUp', gtk.STOCK_DELETE, '_Clean up data directory', - None, 'Move unused PPM files to a backup directory', self.cleanup), + ('CleanUp', gtk.STOCK_DELETE, '_Clean up data directory', "", + 'Move unused PPM files to a backup directory', self.cleanup), ('File', None, '_File'), ('Edit', None, '_Edit'), ('Insert', None, '_Insert'), @@ -939,9 +939,6 @@ class StepEditor(StepMakerWindow): create_shortcut("Next", self.event_next_clicked, "Page_Down") create_shortcut("Previous", self.event_prev_clicked, "Page_Up") - create_shortcut("First", self.event_first_clicked, "Home") - create_shortcut("Last", self.event_last_clicked, "End") - create_shortcut("Delete", self.event_remove_clicked, "Delete") # Add the actiongroup to the uimanager uimanager.insert_action_group(actiongroup, 0)