diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2020-05-16 21:43:05 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2020-05-16 21:43:05 +0000 |
| commit | 57e04a1320f46eece193c3f807c8e058c4f3fb78 (patch) | |
| tree | be6e8ad1f099c3c7c59c5f7d62b6849e6007adf2 | |
| parent | selection: copy: insert line break if either cell is empty (diff) | |
grid: swap_row: remove unused parameter 'initialize'
| -rw-r--r-- | grid.c | 2 | ||||
| -rw-r--r-- | grid.h | 2 | ||||
| -rw-r--r-- | terminal.c | 8 |
3 files changed, 6 insertions, 6 deletions
@@ -10,7 +10,7 @@ #include "util.h" void -grid_swap_row(struct grid *grid, int row_a, int row_b, bool initialize) +grid_swap_row(struct grid *grid, int row_a, int row_b) { assert(grid->offset >= 0); assert(row_a != row_b); @@ -3,7 +3,7 @@ #include <stddef.h> #include "terminal.h" -void grid_swap_row(struct grid *grid, int row_a, int row_b, bool initialize); +void grid_swap_row(struct grid *grid, int row_a, int row_b); struct row *grid_row_alloc(int cols, bool initialize); void grid_row_free(struct row *row); void grid_reflow( @@ -1750,11 +1750,11 @@ term_scroll_partial(struct terminal *term, struct scroll_region region, int rows /* Top non-scrolling region. */ for (int i = region.start - 1; i >= 0; i--) - grid_swap_row(term->grid, i - rows, i, false); + grid_swap_row(term->grid, i - rows, i); /* Bottom non-scrolling region */ for (int i = term->rows - 1; i >= region.end; i--) - grid_swap_row(term->grid, i - rows, i, false); + grid_swap_row(term->grid, i - rows, i); /* Erase scrolled in lines */ for (int r = begin_scrolled_in; r < end_scrolled_in; r++) @@ -1806,11 +1806,11 @@ term_scroll_reverse_partial(struct terminal *term, /* Bottom non-scrolling region */ for (int i = region.end + rows; i < term->rows + rows; i++) - grid_swap_row(term->grid, i, i - rows, false); + grid_swap_row(term->grid, i, i - rows); /* Top non-scrolling region */ for (int i = 0 + rows; i < region.start + rows; i++) - grid_swap_row(term->grid, i, i - rows, false); + grid_swap_row(term->grid, i, i - rows); /* Erase scrolled in lines */ for (int r = start_scrolled_in; r < end_scrolled_in; r++) |
