|
1 | 1 | #A part of NonVisual Desktop Access (NVDA) |
2 | 2 | #This file is covered by the GNU General Public License. |
3 | 3 | #See the file COPYING for more details. |
4 | | -#Copyright (C) 2015-2017 NV Access Limited, Babbage B.V. |
| 4 | +#Copyright (C) 2015-2020 NV Access Limited, Babbage B.V., Accessolutions, Julien Cochuyt |
5 | 5 |
|
6 | 6 | from ctypes import byref |
7 | 7 | from comtypes import COMError |
|
11 | 11 | import UIAHandler |
12 | 12 | from UIAUtils import ( |
13 | 13 | createUIAMultiPropertyCondition, |
14 | | - isUIAElementInWalker, |
15 | 14 | getDeepestLastChildUIAElementInWalker, |
16 | 15 | getUIATextAttributeValueFromRange, |
17 | | - iterUIARangeByUnit |
| 16 | + isUIAElementInWalker, |
| 17 | + iterUIARangeByUnit, |
18 | 18 | ) |
19 | 19 | import documentBase |
20 | 20 | import treeInterceptorHandler |
@@ -417,8 +417,26 @@ def _iterNodesByType(self,nodeType,direction="next",pos=None): |
417 | 417 | condition=createUIAMultiPropertyCondition({UIAHandler.UIA_ControlTypePropertyId:UIAHandler.UIA_EditControlTypeId,UIAHandler.UIA_ValueIsReadOnlyPropertyId:False},{UIAHandler.UIA_ControlTypePropertyId:UIAHandler.UIA_ComboBoxControlTypeId,UIAHandler.UIA_IsTextPatternAvailablePropertyId:True}) |
418 | 418 | return UIAControlQuicknavIterator(nodeType,self,pos,condition,direction) |
419 | 419 | elif nodeType=="formField": |
420 | | - condition=createUIAMultiPropertyCondition({UIAHandler.UIA_ControlTypePropertyId:UIAHandler.UIA_EditControlTypeId,UIAHandler.UIA_ValueIsReadOnlyPropertyId:False},{UIAHandler.UIA_ControlTypePropertyId:UIAHandler.UIA_ListControlTypeId,UIAHandler.UIA_IsKeyboardFocusablePropertyId:True},{UIAHandler.UIA_ControlTypePropertyId:[UIAHandler.UIA_CheckBoxControlTypeId,UIAHandler.UIA_RadioButtonControlTypeId,UIAHandler.UIA_ComboBoxControlTypeId,UIAHandler.UIA_ButtonControlTypeId]}) |
421 | | - return UIAControlQuicknavIterator(nodeType,self,pos,condition,direction) |
| 420 | + condition = createUIAMultiPropertyCondition( |
| 421 | + { |
| 422 | + UIAHandler.UIA_ControlTypePropertyId: UIAHandler.UIA_EditControlTypeId, |
| 423 | + UIAHandler.UIA_ValueIsReadOnlyPropertyId: False |
| 424 | + }, |
| 425 | + { |
| 426 | + UIAHandler.UIA_ControlTypePropertyId: UIAHandler.UIA_ListControlTypeId, |
| 427 | + UIAHandler.UIA_IsKeyboardFocusablePropertyId: True |
| 428 | + }, |
| 429 | + { |
| 430 | + UIAHandler.UIA_ControlTypePropertyId: [ |
| 431 | + UIAHandler.UIA_ButtonControlTypeId, |
| 432 | + UIAHandler.UIA_CheckBoxControlTypeId, |
| 433 | + UIAHandler.UIA_ComboBoxControlTypeId, |
| 434 | + UIAHandler.UIA_RadioButtonControlTypeId, |
| 435 | + UIAHandler.UIA_TabItemControlTypeId, |
| 436 | + ] |
| 437 | + }, |
| 438 | + ) |
| 439 | + return UIAControlQuicknavIterator(nodeType, self, pos, condition, direction) |
422 | 440 | elif nodeType == "landmark": |
423 | 441 | condition = UIAHandler.handler.clientObject.createNotCondition( |
424 | 442 | UIAHandler.handler.clientObject.createPropertyCondition( |
|
0 commit comments