| 443 | } |
| 444 | |
| 445 | bool setHighlightByMouse() |
| 446 | { |
| 447 | if (gps->mouse_y >= 3 && gps->mouse_y < display_max_rows + 3 && |
| 448 | gps->mouse_x >= left_margin && gps->mouse_x < left_margin + max_item_width) |
| 449 | { |
| 450 | int new_index = display_start_offset + gps->mouse_y - 3; |
| 451 | if (size_t(new_index) < display_list.size()) |
| 452 | { |
| 453 | setHighlight(new_index); |
| 454 | feed_mouse_set_highlight = true; |
| 455 | } |
| 456 | |
| 457 | enabler->mouse_lbut = enabler->mouse_rbut = 0; |
| 458 | |
| 459 | return true; |
| 460 | } |
| 461 | |
| 462 | return false; |
| 463 | } |
| 464 | |
| 465 | void sort(bool force_sort = false) |
| 466 | { |