mirror of
https://github.com/weechat/weechat.git
synced 2026-07-01 15:26:37 +02:00
core: automatically add newline char after last pasted line (when pasting many lines with confirmation)
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
WeeChat ChangeLog
|
||||
=================
|
||||
Sébastien Helleu <flashcode@flashtux.org>
|
||||
v0.3.7-rc2, 2012-02-13
|
||||
v0.3.7-rc2, 2012-02-16
|
||||
|
||||
|
||||
Version 0.3.7 (under dev!)
|
||||
--------------------------
|
||||
|
||||
* core: automatically add newline char after last pasted line (when pasting many
|
||||
lines with confirmation)
|
||||
* core: fix bug with layout: assign layout number in buffers when doing
|
||||
/layout save
|
||||
* core: do not auto add space after nick completer if option
|
||||
|
||||
@@ -1422,6 +1422,14 @@ gui_key_get_paste_lines ()
|
||||
void
|
||||
gui_key_paste_accept ()
|
||||
{
|
||||
/* add final '\n' if there is not in pasted text */
|
||||
if ((gui_key_buffer_size > 0)
|
||||
&& (gui_key_buffer[gui_key_buffer_size - 1] != '\r')
|
||||
&& (gui_key_buffer[gui_key_buffer_size - 1] != '\n'))
|
||||
{
|
||||
gui_key_buffer_add ('\n');
|
||||
}
|
||||
|
||||
gui_key_paste_pending = 0;
|
||||
gui_input_paste_pending_signal ();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user