]> asedeno.scripts.mit.edu Git - PuTTY.git/commit
Revamp the terminal paste mechanism using toplevel callbacks.
authorSimon Tatham <anakin@pobox.com>
Sat, 17 Aug 2013 16:06:12 +0000 (16:06 +0000)
committerSimon Tatham <anakin@pobox.com>
Sat, 17 Aug 2013 16:06:12 +0000 (16:06 +0000)
commit7be9af74ec8b97f948d6b3d67ebaf1a97138da33
tree3cbbeb24a3131925a0a552357b825e97b205b8cc
parent75c79e318fffc6db076861856c1320fcea849bf2
Revamp the terminal paste mechanism using toplevel callbacks.

I've removed the ad-hoc front-end bodgery in the Windows and GTK ports
to arrange for term_paste to be called at the right moments, and
instead, terminal.c itself deals with knowing when to send the next
chunk of pasted data using a combination of timers and the new
top-level callback mechanism.

As a happy side effect, it's now all in one place so I can actually
understand what it's doing! It turns out that what all that confusing
code was up to is: send a line of pasted data, and delay sending the
next line until either a CR or LF is returned from the server
(typically indicating that the pasted text has been received and
echoed) or 450ms elapse, whichever comes first.

[originally from svn r10020]
putty.h
terminal.c
terminal.h
unix/gtkwin.c
windows/window.c