ElyTable: a cell scrolls in by the least amount; a drag never scrolls under the pointer (T-02)

This commit is contained in:
ZacharyZhang-NY committed 2026-10-09 09:47:10 -04:00
1 parent c52e1a3b16
commit ecf977364b
6 files changed
+31 -6

No files matched your search

+3 -1
View File
@@ -375,8 +375,9 @@ impl LokView {
}
if batch.cursor != self.cursor {
self.moves += 1;
// A moved cursor stays in view.
// A moved cursor stays in view, but not mid-drag.
if self.viewport.1 > 0.0
&& !self.dragging
&& let Some(cursor) = batch.cursor
{
self.show(cursor, cx);
@@ -385,6 +386,7 @@ impl LokView {
// A moved cell cursor stays in view too.
if batch.cell.cursor != self.cell.cursor
&& self.viewport.1 > 0.0
&& !self.dragging
&& let Some(cell) = batch.cell.cursor
{
self.show(cell, cx);