Skip to content

Commit

Permalink
Fix for escaping a row
Browse files Browse the repository at this point in the history
  • Loading branch information
OwenMcGirr committed Mar 5, 2024
1 parent 3bd12db commit d3e286c
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,10 @@ class ScanTree(
*/
private fun shouldEscapeCurrentRow(): Boolean {
// If at the last node, activate the escape row
if (currentColumn == tree[currentRow].nodes.size - 1 && !shouldEscapeRow) {
if (currentColumn == tree[currentRow].nodes.size - 1 && !shouldEscapeRow && scanDirection == ScanDirection.RIGHT) {
shouldEscapeRow = true
highlightCurrentRow()
} else if (currentColumn == 0 && !shouldEscapeRow && scanDirection == ScanDirection.LEFT) {
shouldEscapeRow = true
highlightCurrentRow()
} else if (shouldEscapeRow) {
Expand Down

0 comments on commit d3e286c

Please sign in to comment.