add some polish to visual mode switching
* switching between visual modes should not reset the begin row/col * selection should be updated as soon as the mode is switched
This commit is contained in:
parent
131cb20584
commit
458087627d
|
@ -139,9 +139,12 @@ static void toggle_visual(VteTerminal *vte, select_info *select, select_mode mod
|
||||||
select->mode = SELECT_ON;
|
select->mode = SELECT_ON;
|
||||||
vte_terminal_select_none(vte);
|
vte_terminal_select_none(vte);
|
||||||
} else {
|
} else {
|
||||||
|
if (select->mode == SELECT_ON) {
|
||||||
|
select->begin_col = select->cursor_col;
|
||||||
|
select->begin_row = select->cursor_row;
|
||||||
|
}
|
||||||
select->mode = mode;
|
select->mode = mode;
|
||||||
select->begin_col = select->cursor_col;
|
update_selection(vte, select);
|
||||||
select->begin_row = select->cursor_row;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue