OSDN Git Service

Mozilla document NVDAObject's treeInterceptorClass property: As Mozilla Gecko 2 does...
authorMichael Curran <mick@kulgan.net>
Thu, 9 Sep 2010 20:06:44 +0000 (06:06 +1000)
committerMichael Curran <mick@kulgan.net>
Thu, 9 Sep 2010 20:06:44 +0000 (06:06 +1000)
source/NVDAObjects/IAccessible/mozilla.py

index ae83f4b..bee1724 100755 (executable)
@@ -72,7 +72,10 @@ class Document(Mozilla):
 \r
        def _get_treeInterceptorClass(self):\r
                states=self.states\r
-               if controlTypes.STATE_READONLY in states and controlTypes.STATE_BUSY not in states and self.windowClassName=="MozillaContentWindowClass":\r
+               ver=_getGeckoVersion(self)\r
+               if (not ver or ver.startswith('1.9')) and self.windowClassName!="MozillaContentWindowClass":\r
+                       return super(Document,self).treeInterceptorClass\r
+               if controlTypes.STATE_READONLY in states and controlTypes.STATE_BUSY not in states:\r
                        import virtualBuffers.gecko_ia2\r
                        return virtualBuffers.gecko_ia2.Gecko_ia2\r
                return super(Document,self).treeInterceptorClass\r