summaryrefslogtreecommitdiff
path: root/src/tabs.py
diff options
context:
space:
mode:
authorFlorent Le Coz <louiz@louiz.org>2011-11-18 19:14:07 +0100
committerFlorent Le Coz <louiz@louiz.org>2011-11-18 19:14:07 +0100
commit7dd8691f8c0193aa6f635374ececa8d3465a943a (patch)
treee2ece5b355281b7a56cc09fc95edcaf8e5941ef7 /src/tabs.py
parent18dbc880e1d72a09caec8163de4f80bf03f567e1 (diff)
downloadpoezio-7dd8691f8c0193aa6f635374ececa8d3465a943a.tar.gz
poezio-7dd8691f8c0193aa6f635374ececa8d3465a943a.tar.bz2
poezio-7dd8691f8c0193aa6f635374ececa8d3465a943a.tar.xz
poezio-7dd8691f8c0193aa6f635374ececa8d3465a943a.zip
Pasting text is now handled has one single big key.
This avoids looping over each char we are pasting, making it a lot faster (actually, should be instant).
Diffstat (limited to 'src/tabs.py')
-rw-r--r--src/tabs.py16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/tabs.py b/src/tabs.py
index f1f4fa16..65dabe20 100644
--- a/src/tabs.py
+++ b/src/tabs.py
@@ -941,7 +941,7 @@ class MucTab(ChatTab):
if not raw and key in self.key_func:
self.key_func[key]()
return False
- self.input.do_command(key)
+ self.input.do_command(key, raw=raw)
empty_after = self.input.get_text() == '' or (self.input.get_text().startswith('/') and not self.input.get_text().startswith('//'))
self.send_composing_chat_state(empty_after)
return False
@@ -1432,7 +1432,7 @@ class PrivateTab(ChatTab):
if not raw and key in self.key_func:
self.key_func[key]()
return False
- self.input.do_command(key)
+ self.input.do_command(key, raw=raw)
if not self.on:
return False
empty_after = self.input.get_text() == '' or (self.input.get_text().startswith('/') and not self.input.get_text().startswith('//'))
@@ -1901,12 +1901,12 @@ class RosterInfoTab(Tab):
return self.name
def on_input(self, key, raw):
- if key == '^M':
+ if raw and key == '^M':
selected_row = self.roster_win.get_selected_row()
- res = self.input.do_command(key)
+ res = self.input.do_command(key, raw=raw)
if res:
return True
- if key == '^M':
+ if raw and key == '^M':
self.core.on_roster_enter_key(selected_row)
return selected_row
elif not raw and key in self.key_func:
@@ -2173,7 +2173,7 @@ class ConversationTab(ChatTab):
if not raw and key in self.key_func:
self.key_func[key]()
return False
- self.input.do_command(key)
+ self.input.do_command(key, raw=raw)
empty_after = self.input.get_text() == '' or (self.input.get_text().startswith('/') and not self.input.get_text().startswith('//'))
self.send_composing_chat_state(empty_after)
return False
@@ -2355,7 +2355,7 @@ class MucListTab(Tab):
self.complete_commands(self.input)
def on_input(self, key, raw):
- res = self.input.do_command(key)
+ res = self.input.do_command(key, raw=raw)
if res:
return True
if not raw and key in self.key_func:
@@ -2400,7 +2400,7 @@ class SimpleTextTab(Tab):
self.input.do_command("/") # we add the slash
def on_input(self, key, raw):
- res = self.input.do_command(key)
+ res = self.input.do_command(key, raw=raw)
if res:
return True
if not raw and key in self.key_func: