Fix cursor getting stuck when Enter pressed on last row
move_selection() only clamped at 0, letting the row/col index go past the last valid item. Selected_cell_key() would then return None, leaving the cursor in a phantom position with no selectable cell. Now clamp both row and col against the actual item count so pressing Enter on the last row keeps the cursor on that row. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
144
whatever.improv
144
whatever.improv
@ -128,29 +128,6 @@
|
||||
"Number": 3.0
|
||||
}
|
||||
],
|
||||
[
|
||||
[
|
||||
[
|
||||
"Month",
|
||||
"Janury"
|
||||
],
|
||||
[
|
||||
"Payer",
|
||||
"Bernadette"
|
||||
],
|
||||
[
|
||||
"Recipient",
|
||||
"Bob"
|
||||
],
|
||||
[
|
||||
"Type",
|
||||
"Food"
|
||||
]
|
||||
],
|
||||
{
|
||||
"Number": 12.0
|
||||
}
|
||||
],
|
||||
[
|
||||
[
|
||||
[
|
||||
@ -196,6 +173,121 @@
|
||||
{
|
||||
"Number": 5.0
|
||||
}
|
||||
],
|
||||
[
|
||||
[
|
||||
[
|
||||
"Month",
|
||||
"February"
|
||||
],
|
||||
[
|
||||
"Payer",
|
||||
"Bernadette"
|
||||
],
|
||||
[
|
||||
"Recipient",
|
||||
"Bob"
|
||||
],
|
||||
[
|
||||
"Type",
|
||||
"Medical"
|
||||
]
|
||||
],
|
||||
{
|
||||
"Number": 33.0
|
||||
}
|
||||
],
|
||||
[
|
||||
[
|
||||
[
|
||||
"Month",
|
||||
"February"
|
||||
],
|
||||
[
|
||||
"Payer",
|
||||
"Bernadette"
|
||||
],
|
||||
[
|
||||
"Recipient",
|
||||
"Bob"
|
||||
],
|
||||
[
|
||||
"Type",
|
||||
"Gas"
|
||||
]
|
||||
],
|
||||
{
|
||||
"Number": 55.0
|
||||
}
|
||||
],
|
||||
[
|
||||
[
|
||||
[
|
||||
"Month",
|
||||
"February"
|
||||
],
|
||||
[
|
||||
"Payer",
|
||||
"Bernadette"
|
||||
],
|
||||
[
|
||||
"Recipient",
|
||||
"Bob"
|
||||
],
|
||||
[
|
||||
"Type",
|
||||
"Food"
|
||||
]
|
||||
],
|
||||
{
|
||||
"Number": 4.0
|
||||
}
|
||||
],
|
||||
[
|
||||
[
|
||||
[
|
||||
"Month",
|
||||
"February"
|
||||
],
|
||||
[
|
||||
"Payer",
|
||||
"Bernadette"
|
||||
],
|
||||
[
|
||||
"Recipient",
|
||||
"Bob"
|
||||
],
|
||||
[
|
||||
"Type",
|
||||
"Clothing"
|
||||
]
|
||||
],
|
||||
{
|
||||
"Text": "i5"
|
||||
}
|
||||
],
|
||||
[
|
||||
[
|
||||
[
|
||||
"Month",
|
||||
"Janury"
|
||||
],
|
||||
[
|
||||
"Payer",
|
||||
"Bernadette"
|
||||
],
|
||||
[
|
||||
"Recipient",
|
||||
"Bob"
|
||||
],
|
||||
[
|
||||
"Type",
|
||||
"Food"
|
||||
]
|
||||
],
|
||||
{
|
||||
"Number": 12.0
|
||||
}
|
||||
]
|
||||
],
|
||||
"formulas": [],
|
||||
@ -217,11 +309,11 @@
|
||||
"row_offset": 0,
|
||||
"col_offset": 0,
|
||||
"selected": [
|
||||
1,
|
||||
1
|
||||
6,
|
||||
2
|
||||
]
|
||||
}
|
||||
},
|
||||
"active_view": "Default",
|
||||
"next_category_id": 4
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user