Fix-up of PR 13271. (#13560)
Link to issue number:
Fix-up of PR #13271
Summary of the issue:
PR #13271 moved most of the logic for retrieving content in syslistview32 controls in process. As part of this work _getColumnLocationRaw was changed to return an instance of ctypes.wintypes.RECT rather than one of locationHelper classes, additionally the returned coordinates were no longer normalized. Some places in NVDA expects _getColumnLocationRaw to return normalized coordinates - in particular this affects the list control in Tween and my add-on for Becky! Internet Mail. The error when trying to navigate the list was as follows:
ERROR - scriptHandler.executeScript (21:29:59.073) - MainThread (1152):
error executing script: <bound method GlobalCommands.script_reportCurrentFocus of <globalCommands.GlobalCommands object at 0x064ECAD0>> with gesture 'NVDA+tab'
Traceback (most recent call last):
File "scriptHandler.pyc", line 212, in executeScript
File "globalCommands.pyc", line 2032, in script_reportCurrentFocus
File "speech\speech.pyc", line 561, in speakObject
File "speech\speech.pyc", line 604, in getObjectSpeech
File "speech\speech.pyc", line 453, in getObjectPropertiesSpeech
File "baseObject.pyc", line 42, in __get__
File "baseObject.pyc", line 146, in _getPropertyViaCache
File "appModules\tween.pyc", line 26, in _get_name
File "baseObject.pyc", line 42, in __get__
File "baseObject.pyc", line 146, in _getPropertyViaCache
File "NVDAObjects\IAccessible\sysListView32.pyc", line 531, in _get_name
File "NVDAObjects\IAccessible\sysListView32.pyc", line 459, in _getColumnContent
File "appModules\tween.pyc", line 42, in _getColumnContentRaw
TypeError: cannot unpack non-iterable RECT object
Note that for these controls we cannot just use location returned from _getColumnLocation since indexes provided to it are not constant for a given column - they can change for example when user reorders columns.
Description of how this pull request fixes the issue:
Renames raw getters to rawInProc to clarify that these methods are used in-process
Add docstrings to clarify when and why these methods are used
The location normalization is once again performed by _getColumnLocationRaw
In the Tween app Module annoying decorational Unicode symbol is removed from the columns header - this is not strictly related to the main issue.