[orca] Ensure we use keyval_name when event_string is absent for keyboard events
- From: Joanmarie Diggs <joanied src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca] Ensure we use keyval_name when event_string is absent for keyboard events
- Date: Wed, 28 Nov 2018 16:32:55 +0000 (UTC)
commit 77a4a1986ca4d2d3e4a9f7343a16ee419b0475b7
Author: Joanmarie Diggs <jdiggs igalia com>
Date: Wed Nov 28 11:31:41 2018 -0500
Ensure we use keyval_name when event_string is absent for keyboard events
src/orca/script.py | 5 +++++
1 file changed, 5 insertions(+)
---
diff --git a/src/orca/script.py b/src/orca/script.py
index 60454704d..7366be50c 100644
--- a/src/orca/script.py
+++ b/src/orca/script.py
@@ -398,6 +398,11 @@ class Script:
except:
msg = 'ERROR: Exception getting keyval_name for id: %d' % keyboardEvent.id
debug.println(debug.LEVEL_INFO, msg, True)
+ else:
+ if keyboardEvent.event_string == '':
+ msg = 'INFO: Setting event_string to: %s' % keyboardEvent.keyval_name
+ debug.println(debug.LEVEL_INFO, msg, True)
+ keyboardEvent.event_string = keyboardEvent.keyval_name
def consumesKeyboardEvent(self, keyboardEvent):
"""Called when a key is pressed on the keyboard.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]