Better handling of refocus on middle click
This commit is contained in:
parent
56e93ee30b
commit
3e71f13fc7
11
terminator
11
terminator
|
@ -175,7 +175,7 @@ class TerminatorTerm (gtk.VBox):
|
|||
self._vte.connect ("grab-focus", self.on_vte_focus)
|
||||
self._vte.connect ("focus-out-event", self.on_vte_focus_out)
|
||||
self._vte.connect ("focus-in-event", self.on_vte_focus_in)
|
||||
self._vte.connect ("button-release-event", self.on_button_release)
|
||||
|
||||
|
||||
exit_action = self.conf.exit_action
|
||||
if exit_action == "restart":
|
||||
|
@ -199,11 +199,6 @@ class TerminatorTerm (gtk.VBox):
|
|||
os.putenv ('COLORTERM', 'gnome-terminal')
|
||||
dbg ('SEGBUG: TerminatorTerm __init__ complete')
|
||||
|
||||
def on_button_release(self, widget, event):
|
||||
#LP#242612 we need to give focus on the widget where the paste occured
|
||||
if event.button == 2:
|
||||
widget.grab_focus()
|
||||
|
||||
def on_drag_begin(self, widget, drag_context, data):
|
||||
dbg ('Drag begins')
|
||||
widget.drag_source_set_icon_pixbuf(self.terminator.icon_theme.load_icon (APP_NAME, 48, 0))
|
||||
|
@ -585,7 +580,9 @@ text/plain
|
|||
return False
|
||||
|
||||
# Left mouse button should transfer focus to this vte widget
|
||||
if event.button == 1:
|
||||
#LP#242612:
|
||||
# we also need to give focus on the widget where the paste occured
|
||||
if event.button in (1 ,2):
|
||||
self._vte.grab_focus ()
|
||||
return False
|
||||
|
||||
|
|
Loading…
Reference in New Issue