[orca] Only treat URIs that start with "http" as top-level web app candidates
- From: Joanmarie Diggs <joanied src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [orca] Only treat URIs that start with "http" as top-level web app candidates
- Date: Fri, 23 Oct 2015 04:18:11 +0000 (UTC)
commit 07f7f0686c7e0276d18e5dd7bc404142f21f128e
Author: Joanmarie Diggs <jdiggs igalia com>
Date: Fri Oct 23 00:13:16 2015 -0400
Only treat URIs that start with "http" as top-level web app candidates
In some configurations, we're seeing URIs that begin with "about"
having ROLE_EMBEDDED. And since this is for auto-sticky focus mode,
http/https is (so far) what we really care about.
src/orca/scripts/web/script_utilities.py | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/orca/scripts/web/script_utilities.py b/src/orca/scripts/web/script_utilities.py
index e47afb6..78733b0 100644
--- a/src/orca/scripts/web/script_utilities.py
+++ b/src/orca/scripts/web/script_utilities.py
@@ -1309,10 +1309,10 @@ class Utilities(script_utilities.Utilities):
if role == pyatspi.ROLE_EMBEDDED and not self.getDocumentForObject(obj.parent):
uri = self.documentFrameURI()
- if uri:
- msg = "WEB: %s is top-level web application. URI: %s" % (obj, uri)
- debug.println(debug.LEVEL_INFO, msg)
- return True
+ rv = bool(uri and uri.startswith("http"))
+ msg = "WEB: %s is top-level web application: %s (URI: %s)" % (obj, rv, uri)
+ debug.println(debug.LEVEL_INFO, msg)
+ return rv
return False
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]