From 7a417672189f383de4bb4065c1ab8670d2f31765 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 8 Feb 2012 16:08:07 +0100 Subject: [PATCH] Add shortcuts in tooltips review243001 --- tryton/gui/window/view_form/view/form_gtk/many2many.py | 2 +- tryton/gui/window/view_form/view/form_gtk/many2one.py | 8 ++++---- tryton/gui/window/view_form/view/form_gtk/one2many.py | 10 +++++----- tryton/gui/window/win_form.py | 4 ++-- 4 files changed, 12 insertions(+), 12 deletions(-) diff --git a/tryton/gui/window/view_form/view/form_gtk/many2many.py b/tryton/gui/window/view_form/view/form_gtk/many2many.py index c2eb317350..46e96b3b85 100644 --- a/tryton/gui/window/view_form/view/form_gtk/many2many.py +++ b/tryton/gui/window/view_form/view/form_gtk/many2many.py @@ -52,7 +52,7 @@ class Many2Many(WidgetInterface): hbox.pack_start(self.but_add, expand=False, fill=False) self.but_remove = gtk.Button() - tooltips.set_tip(self.but_remove, _('Remove')) + tooltips.set_tip(self.but_remove, _('Remove ')) self.but_remove.connect('clicked', self._sig_remove) img_remove = gtk.Image() img_remove.set_from_stock('tryton-list-remove', diff --git a/tryton/gui/window/view_form/view/form_gtk/many2one.py b/tryton/gui/window/view_form/view/form_gtk/many2one.py index 700744cda8..adc18c80f8 100644 --- a/tryton/gui/window/view_form/view/form_gtk/many2one.py +++ b/tryton/gui/window/view_form/view/form_gtk/many2one.py @@ -62,8 +62,8 @@ class Many2One(WidgetInterface): self.widget.set_focus_chain([self.wid_text]) self.tooltips = common.Tooltips() - self.tooltips.set_tip(self.but_new, _('Create a new record')) - self.tooltips.set_tip(self.but_open, _('Open a record')) + self.tooltips.set_tip(self.but_new, _('Create a new record ')) + self.tooltips.set_tip(self.but_open, _('Open a record ')) self.tooltips.enable() self._readonly = False @@ -303,10 +303,10 @@ class Many2One(WidgetInterface): value = field.get(record) if self.has_target(value) and current_stock != 'tryton-open': img.set_from_stock('tryton-open', gtk.ICON_SIZE_SMALL_TOOLBAR) - self.tooltips.set_tip(self.but_open, _('Open a record')) + self.tooltips.set_tip(self.but_open, _('Open a record ')) elif not self.has_target(value) and current_stock != 'tryton-find': img.set_from_stock('tryton-find', gtk.ICON_SIZE_SMALL_TOOLBAR) - self.tooltips.set_tip(self.but_open, _('Search a record')) + self.tooltips.set_tip(self.but_open, _('Search a record ')) self.changed = True def _populate_popup(self, widget, menu): diff --git a/tryton/gui/window/view_form/view/form_gtk/one2many.py b/tryton/gui/window/view_form/view/form_gtk/one2many.py index 42ad8c7767..0454fed857 100644 --- a/tryton/gui/window/view_form/view/form_gtk/one2many.py +++ b/tryton/gui/window/view_form/view/form_gtk/one2many.py @@ -53,7 +53,7 @@ class One2Many(WidgetInterface): hbox.pack_start(self.but_add, expand=False, fill=False) self.but_remove = gtk.Button() - tooltips.set_tip(self.but_remove, _('Remove')) + tooltips.set_tip(self.but_remove, _('Remove ')) self.but_remove.connect('clicked', self._sig_remove, True) img_remove = gtk.Image() img_remove.set_from_stock('tryton-list-remove', @@ -66,7 +66,7 @@ class One2Many(WidgetInterface): hbox.pack_start(gtk.VSeparator(), expand=False, fill=True) self.but_new = gtk.Button() - tooltips.set_tip(self.but_new, _('Create a new record')) + tooltips.set_tip(self.but_new, _('Create a new record ')) self.but_new.connect('clicked', self._sig_new) img_new = gtk.Image() img_new.set_from_stock('tryton-new', gtk.ICON_SIZE_SMALL_TOOLBAR) @@ -76,7 +76,7 @@ class One2Many(WidgetInterface): hbox.pack_start(self.but_new, expand=False, fill=False) self.but_open = gtk.Button() - tooltips.set_tip(self.but_open, _('Edit selected record')) + tooltips.set_tip(self.but_open, _('Edit selected record ')) self.but_open.connect('clicked', self._sig_edit) img_open = gtk.Image() img_open.set_from_stock('tryton-open', gtk.ICON_SIZE_SMALL_TOOLBAR) @@ -86,7 +86,7 @@ class One2Many(WidgetInterface): hbox.pack_start(self.but_open, expand=False, fill=False) self.but_del = gtk.Button() - tooltips.set_tip(self.but_del, _('Delete selected record')) + tooltips.set_tip(self.but_del, _('Delete selected record ')) self.but_del.connect('clicked', self._sig_remove, False) img_del = gtk.Image() img_del.set_from_stock('tryton-delete', gtk.ICON_SIZE_SMALL_TOOLBAR) @@ -96,7 +96,7 @@ class One2Many(WidgetInterface): hbox.pack_start(self.but_del, expand=False, fill=False) self.but_undel = gtk.Button() - tooltips.set_tip(self.but_undel, _('Undelete selected record')) + tooltips.set_tip(self.but_undel, _('Undelete selected record ')) self.but_undel.connect('clicked', self._sig_undelete) img_undel = gtk.Image() img_undel.set_from_stock('tryton-undo', gtk.ICON_SIZE_SMALL_TOOLBAR) diff --git a/tryton/gui/window/win_form.py b/tryton/gui/window/win_form.py index 9212e1a939..50af9fad59 100644 --- a/tryton/gui/window/win_form.py +++ b/tryton/gui/window/win_form.py @@ -118,7 +118,7 @@ class WinForm(NoModal): tooltips = common.Tooltips() self.but_new = gtk.Button() - tooltips.set_tip(self.but_new, _('Create a new record')) + tooltips.set_tip(self.but_new, _('Create a new record ')) self.but_new.connect('clicked', self._sig_new) img_new = gtk.Image() img_new.set_from_stock('tryton-new', gtk.ICON_SIZE_SMALL_TOOLBAR) @@ -128,7 +128,7 @@ class WinForm(NoModal): hbox.pack_start(self.but_new, expand=False, fill=False) self.but_del = gtk.Button() - tooltips.set_tip(self.but_del, _('Delete selected record')) + tooltips.set_tip(self.but_del, _('Delete selected record ')) self.but_del.connect('clicked', self._sig_remove) img_del = gtk.Image() img_del.set_from_stock('tryton-delete',