1
0
mirror of https://github.com/irssi/irssi.git synced 2024-10-27 05:20:20 -04:00

Increment paste_keycount when the key before the one that starts a

possible pasting is not a '\r' or '\n'.


git-svn-id: http://svn.irssi.org/repos/irssi/trunk@4467 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
Emanuele Giaquinta 2007-04-28 11:45:34 +00:00 committed by exg
parent 39d15501c8
commit 83c178c169

View File

@ -398,8 +398,10 @@ static int check_pasting(unichar key, int diff)
paste_line_count = 0; paste_line_count = 0;
paste_keycount = 0; paste_keycount = 0;
g_array_set_size(paste_buffer, 0); g_array_set_size(paste_buffer, 0);
if (prev_key != '\r' && prev_key != '\n') if (prev_key != '\r' && prev_key != '\n') {
paste_keycount++;
g_array_append_val(paste_buffer, prev_key); g_array_append_val(paste_buffer, prev_key);
}
} else if (paste_state > 0 && diff > paste_detect_time && } else if (paste_state > 0 && diff > paste_detect_time &&
paste_line_count == 0) { paste_line_count == 0) {
/* reset paste state */ /* reset paste state */