[orca] Rename isVisibleRegion() to containsRegion() since the latter is what it returns



commit 91e8f167f5d7435f6ecc0ab722bc60866f32c002
Author: Joanmarie Diggs <jdiggs igalia com>
Date:   Sat Feb 22 16:04:21 2014 -0500

    Rename isVisibleRegion() to containsRegion() since the latter is what it returns

 src/orca/flat_review.py      |    6 +++---
 src/orca/script_utilities.py |    4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)
---
diff --git a/src/orca/flat_review.py b/src/orca/flat_review.py
index d50a9dc..0aa6a9f 100644
--- a/src/orca/flat_review.py
+++ b/src/orca/flat_review.py
@@ -774,7 +774,7 @@ class Context:
             else:
                 [x, y, width, height] = text.getRangeExtents(
                         substringStartOffset, substringEndOffset, 0)
-                if self.script.utilities.isVisibleRegion(
+                if self.script.utilities.containsRegion(
                         x, y, width, height,
                         cliprect.x, cliprect.y,
                         cliprect.width, cliprect.height):
@@ -1075,7 +1075,7 @@ class Context:
         #
         extents = icomponent.getExtents(0)
 
-        if not self.script.utilities.isVisibleRegion(
+        if not self.script.utilities.containsRegion(
                 extents.x, extents.y,
                 extents.width, extents.height,
                 cliprect.x, cliprect.y,
@@ -1125,7 +1125,7 @@ class Context:
             [width, height] = iimage.getImageSize()
 
             if width != 0 and height != 0 \
-               and self.script.utilities.isVisibleRegion(
+               and self.script.utilities.containsRegion(
                     x, y, width, height,
                     cliprect.x, cliprect.y,
                     cliprect.width, cliprect.height):
diff --git a/src/orca/script_utilities.py b/src/orca/script_utilities.py
index be6d35c..7679fe2 100644
--- a/src/orca/script_utilities.py
+++ b/src/orca/script_utilities.py
@@ -1383,7 +1383,7 @@ class Utilities:
                     if stateset.contains(pyatspi.STATE_SHOWING) \
                        and (extents.x >= 0) and (extents.y >= 0) \
                        and (extents.width > 0) and (extents.height > 0) \
-                       and self.isVisibleRegion(
+                       and self.containsRegion(
                             extents.x, extents.y,
                             extents.width, extents.height,
                             parentExtents.x, parentExtents.y,
@@ -2515,7 +2515,7 @@ class Utilities:
                or character == self._script.NO_BREAK_SPACE_CHARACTER
 
     @staticmethod
-    def isVisibleRegion(ax, ay, awidth, aheight, bx, by, bwidth, bheight):
+    def containsRegion(ax, ay, awidth, aheight, bx, by, bwidth, bheight):
         """Returns true if any portion of region 'a' is in region 'b'"""
 
         highestBottom = min(ay + aheight, by + bheight)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]