ci2.focus = p;
ci2.key = "Move-View-Small";
ci2.numeric = RPT_NUM(ci);
- ci2.mark = &(*ci->pointp)->m;
- ci2.pointp = ci->pointp;
+ ci2.mark = ci->mark;
if (ci->hy == mid-1) {
/* scroll up */
{
struct move_command *mv = container_of(ci->comm, struct move_command, cmd);
struct pane *cursor_pane = pane_with_cursor(ci->home, NULL, NULL);
- struct point *pt = *ci->pointp;
int old_x = -1;
struct cmd_info ci2 = {0};
int ret = 0;
ci2.focus = ci->focus;
ci2.key = mv->type;
ci2.numeric = mv->direction * RPT_NUM(ci);
- ci2.mark = &pt->m;
- ci2.pointp = ci->pointp;
+ ci2.mark = ci->mark;
ret = key_handle_focus(&ci2);
if (!ret)
ci2.y = 0;
else
ci2.y = cursor_pane->h - 1;
- ci2.pointp = ci->pointp;
key_handle_xy(&ci2);
}
DEF_CMD(render_lines_set_cursor)
{
struct pane *p = ci->home;
- struct point **ptp = ci->pointp;
struct rl_data *rl = p->data;
struct rl_mark *m;
int y = rl->header_lines - rl->skip_lines;
if (o >= 0) {
struct mark *m2 = call_render_line_offset(p, m, o);
if (m2) {
- point_to_mark(*ptp, m2);
+ mark_to_mark(ci->mark, m2);
mark_free(m2);
found = 1;
}
*/
struct pane *p = ci->home;
struct rl_data *rl = p->data;
- struct point **ptp = ci->pointp;
struct cmd_info ci2 = {0};
int target_x, target_y;
int o = -1;
ci2.numeric -= 1;
else
ci2.numeric += 1;
- ci2.mark = &(*ptp)->m;
- ci2.pointp = ci->pointp;
+ ci2.mark = ci->mark;
if (!key_handle_focus(&ci2))
return -1;
if (RPT_NUM(ci) > 0) {