orca r4418 - in branches/gnome-2-24: . src/orca/scripts/toolkits/Gecko



Author: joanied
Date: Fri Jan  9 18:35:28 2009
New Revision: 4418
URL: http://svn.gnome.org/viewvc/orca?rev=4418&view=rev

Log:
* src/orca/scripts/toolkits/Gecko/script.py:
  Fix for bug #566955 - Need to remove extra whitespace from braille
  output for Firefox 3.x.


Modified:
   branches/gnome-2-24/ChangeLog
   branches/gnome-2-24/src/orca/scripts/toolkits/Gecko/script.py

Modified: branches/gnome-2-24/src/orca/scripts/toolkits/Gecko/script.py
==============================================================================
--- branches/gnome-2-24/src/orca/scripts/toolkits/Gecko/script.py	(original)
+++ branches/gnome-2-24/src/orca/scripts/toolkits/Gecko/script.py	Fri Jan  9 18:35:28 2009
@@ -5050,7 +5050,15 @@
                and extents != prevExtents \
                and lastExtents != prevExtents:
                 toAdd = self.getObjectsFromEOCs(prevObj, pOffset, boundary)
-                objects[0:0] = toAdd
+                # Depending on the line, there's a chance that we got our
+                # current object as part of toAdd. Check for dupes and just
+                # add up to the current object if we find them.
+                #
+                try:
+                    index = toAdd.index(objects[0])
+                except:
+                    index = len(toAdd)
+                objects[0:0] = toAdd[0:index]
             else:
                 break
 
@@ -5104,20 +5112,6 @@
 
             lastExtents = nextExtents
 
-        # Get rid of duplicates (real and functional).
-        #
-        parentLink = None
-        for o in objects:
-            if objects.count(o) > 1:
-                objects.pop(objects.index(o))
-            elif o[0].parent.getRole() == pyatspi.ROLE_LINK:
-                if not parentLink:
-                    parentLink = o[0].parent
-                elif self.isSameObject(o[0].parent, parentLink):
-                    objects.pop(objects.index(o))
-                else:
-                    parentLink = o[0].parent
-
         return objects
 
     def getObjectContentsAtOffset(self, obj, characterOffset):



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