projects
/
u
/
mdw
/
putty
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use SetCapture() to fix the problem with double-clicks on saved sessions
[u/mdw/putty]
/
terminal.c
diff --git
a/terminal.c
b/terminal.c
index
a935be7
..
2c41145
100644
(file)
--- a/
terminal.c
+++ b/
terminal.c
@@
-628,6
+628,8
@@
void term_out(void) {
scroll (marg_t, marg_b, 1, TRUE);
else if (curs_y < rows-1)
curs_y++;
scroll (marg_t, marg_b, 1, TRUE);
else if (curs_y < rows-1)
curs_y++;
+ if (cfg.lfhascr)
+ curs_x = 0;
fix_cpos;
wrapnext = FALSE;
disptop = scrtop;
fix_cpos;
wrapnext = FALSE;
disptop = scrtop;
@@
-1343,7
+1345,13
@@
void term_mouse (Mouse_Button b, Mouse_Action a, int x, int y) {
if (y<0) y = 0;
if (y>=rows) y = rows-1;
if (y<0) y = 0;
if (y>=rows) y = rows-1;
- if (x<0) x = 0;
+ if (x<0) {
+ if (y > 0) {
+ x = cols-1;
+ y--;
+ } else
+ x = 0;
+ }
if (x>=cols) x = cols-1;
selpoint = disptop + y * (cols+1) + x;
if (x>=cols) x = cols-1;
selpoint = disptop + y * (cols+1) + x;