From adf5a977a970fff1e3b42655ade0c3f61c3a8958 Mon Sep 17 00:00:00 2001 From: Florent Le Coz Date: Tue, 15 Feb 2011 20:49:54 +0100 Subject: =?UTF-8?q?Remove=20^J=20from=20the=20shortcuts=20triggering=20the?= =?UTF-8?q?=20Enter=20event,=20because=20we=E2=80=99ll=20use=20it=20to=20a?= =?UTF-8?q?dd=20a=20(real)=20\n=20into=20the=20input=E2=80=99s=20text.=20A?= =?UTF-8?q?lso=20remove=20"\n"=20because=20it=E2=80=99s=20useless?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/tabs.py | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'src/tabs.py') diff --git a/src/tabs.py b/src/tabs.py index 9beb4499..209649ac 100644 --- a/src/tabs.py +++ b/src/tabs.py @@ -219,16 +219,14 @@ class ChatTab(Tab): """ A tab containing a chat of any type. Just use this class instead of Tab if the tab needs a recent-words completion - Also, \n, ^J and ^M are already bound to on_enter + Also, ^M is already bound to on_enter And also, add the /say command """ def __init__(self, core, room): Tab.__init__(self, core) self._room = room self.key_func['M-/'] = self.last_words_completion - self.key_func['^J'] = self.on_enter self.key_func['^M'] = self.on_enter - self.key_func['\n'] = self.on_enter self.commands['say'] = (self.command_say, _("""Usage: /say \nSay: Just send the message. Useful if you want your message to begin with a '/'"""), None) @@ -282,9 +280,7 @@ class InfoTab(ChatTab): self.input = windows.Input() self.name = "Info" self.color_state = theme.COLOR_TAB_NORMAL - self.key_func['^J'] = self.on_enter self.key_func['^M'] = self.on_enter - self.key_func['\n'] = self.on_enter self.key_func['^I'] = self.completion self.key_func['M-i'] = self.completion self.resize() @@ -804,7 +800,6 @@ class RosterInfoTab(Tab): self.set_color_state(theme.COLOR_TAB_NORMAL) self.key_func['^I'] = self.completion self.key_func['M-i'] = self.completion - self.key_func["^J"] = self.on_enter self.key_func["^M"] = self.on_enter self.key_func[' '] = self.on_space self.key_func["/"] = self.on_slash @@ -1217,7 +1212,6 @@ class MucListTab(Tab): self.key_func["/"] = self.on_slash self.key_func['j'] = self.join_selected self.key_func['J'] = self.join_selected_no_focus - self.key_func['^J'] = self.join_selected self.key_func['^M'] = self.join_selected self.commands['close'] = (self.close, _("Usage: /close\nClose: Just close this tab"), None) self.resize() -- cgit v1.2.3