tweaks: elide a redundant variable

This commit is contained in:
Benno Schulenberg 2024-03-30 11:44:18 +01:00
parent 25d07b422d
commit f2bfa53b61
1 changed files with 1 additions and 2 deletions

View File

@ -1339,7 +1339,6 @@ int do_mouse(void)
size_t leftedge;
#ifndef NANO_TINY
size_t current_x_save = openfile->current_x;
bool sameline = (click_row == openfile->cursor_row);
if (ISSET(SOFTWRAP))
leftedge = leftedge_for(xplustabs(), openfile->current);
@ -1359,7 +1358,7 @@ int do_mouse(void)
#ifndef NANO_TINY
/* Clicking where the cursor is toggles the mark, as does clicking
* beyond the line length with the cursor at the end of the line. */
if (sameline && openfile->current_x == current_x_save) {
if (row_count == 0 && openfile->current_x == current_x_save) {
do_mark();
if (ISSET(STATEFLAGS))
titlebar(NULL);