* Move selection by the given rows and cols */
| 517 | * Move selection by the given rows and cols |
| 518 | */ |
| 519 | void CsvGrid::moveSelection(int rows, int cols) { |
| 520 | DEBUG_PRINTF("#### CsvGrid::moveSelection: %d, %d\n", rows, cols); |
| 521 | int row_top, col_left, row_bot, col_right; |
| 522 | get_selection(row_top, col_left, row_bot, col_right); |
| 523 | row_top += rows; |
| 524 | row_bot += rows; |
| 525 | col_left += cols; |
| 526 | col_right += cols; |
| 527 | if( row_top < 0 ) |
| 528 | row_top = 0; |
| 529 | if( col_left < 0 ) |
| 530 | col_left = 0; |
| 531 | set_selection(row_top, col_left, row_bot, col_right); |
| 532 | } |
| 533 | |
| 534 | |
| 535 |
no outgoing calls
no test coverage detected