[orca] Braille: Ensure focused region starts the display when panToCursor (take 2)
- From: Joanmarie Diggs <joanied src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca] Braille: Ensure focused region starts the display when panToCursor (take 2)
- Date: Sat, 25 Apr 2020 20:28:19 +0000 (UTC)
commit cf53c5a9ce5857d9db3dc93503728be1cfdfe877
Author: Joanmarie Diggs <jdiggs igalia com>
Date: Sat Apr 25 16:08:32 2020 -0400
Braille: Ensure focused region starts the display when panToCursor (take 2)
If the string and offset already fit on the display, don't reset the
recently-calculated offset to 0.
src/orca/braille.py | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/src/orca/braille.py b/src/orca/braille.py
index 825f7d4bb..5ad9fc8a5 100644
--- a/src/orca/braille.py
+++ b/src/orca/braille.py
@@ -1180,9 +1180,8 @@ def refresh(panToCursor=True,
# right of the display if we need to pan right.
#
if panToCursor and (cursorOffset >= 0):
- if len(string) <= _displaySize[0] \
- and cursorOffset < _displaySize[0]:
- viewport[0] = 0
+ if len(string) <= _displaySize[0] and cursorOffset < _displaySize[0]:
+ pass
elif targetCursorCell:
viewport[0] = max(0, cursorOffset - targetCursorCell + 1)
elif cursorOffset < viewport[0]:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]