Skip to content

Commit

Permalink
Merge branch 't5049' into next. Incubates #5049
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelDCurran committed Jun 9, 2015
2 parents c8ce76c + bc74d9e commit faffb8a
Show file tree
Hide file tree
Showing 5 changed files with 53 additions and 1 deletion.
14 changes: 14 additions & 0 deletions source/NVDAObjects/UIA/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -693,6 +693,20 @@ def _get_positionInfo(self):
parentCount+=1
return info

def _get_controllerFor(self):
e=self.UIAElement.getCurrentPropertyValue(UIAHandler.UIA_ControllerForPropertyId)
if UIAHandler.handler.clientObject.checkNotSupported(e):
return None
a=e.QueryInterface(UIAHandler.IUIAutomationElementArray)
objList=[]
for index in xrange(a.length):
e=a.getElement(index)
e=e.buildUpdatedCache(UIAHandler.handler.baseCacheRequest)
obj=UIA(UIAElement=e)
if obj:
objList.append(obj)
return objList

def event_UIA_elementSelected(self):
self.event_stateChange()

Expand Down
4 changes: 4 additions & 0 deletions source/NVDAObjects/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,10 @@ def _get_description(self):
"""
return ""

def _get_controllerFor(self):
"""Retreaves the object/s that this object controls."""
return []

def _get_actionCount(self):
"""Retreaves the number of actions supported by this object."""
return 0
Expand Down
28 changes: 28 additions & 0 deletions source/appModules/searchui.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
#A part of NonVisual Desktop Access (NVDA)
#Copyright (C) 2015 NV Access Limited
#This file is covered by the GNU General Public License.
#See the file COPYING for more details.

import appModuleHandler
import controlTypes
import api
import speech
from NVDAObjects.UIA import UIA

# Windows 10 Search UI suggestion list item
class SuggestionListItem(UIA):

role=controlTypes.ROLE_LISTITEM

def event_UIA_elementSelected(self):
focusControllerFor=api.getFocusObject().controllerFor
if len(focusControllerFor)>0 and focusControllerFor[0].appModule is self.appModule:
speech.cancelSpeech()
api.setNavigatorObject(self)
self.reportFocus()

class AppModule(appModuleHandler.AppModule):

def chooseNVDAObjectOverlayClasses(self,obj,clsList):
if isinstance(obj,UIA) and obj.role==controlTypes.ROLE_DATAITEM and isinstance(obj.parent,UIA) and obj.parent.role==controlTypes.ROLE_LIST:
clsList.insert(0,SuggestionListItem)
2 changes: 1 addition & 1 deletion source/versionInfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ def _updateVersionFromVCS():
# Otherwise, py2exe will break.
name="NVDA"
longName=_("NonVisual Desktop Access")
version="2015.2dev"
version="2015.3dev"
publisher="unknown"
updateVersionType=None
try:
Expand Down
6 changes: 6 additions & 0 deletions user_docs/en/changes.t2t
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@

%!includeconf: ../changes.t2tconf

= 2015.3 =

== New Features ==
- The existance of spelling errors is announced in editable fields for Internet Explorer and other MSHTML controls. (#4174)


= 2015.2 =
Highlights of this release include the ability to read charts in Microsoft Excel and support for reading and interactive navigation of mathematical content.

Expand Down

0 comments on commit faffb8a

Please sign in to comment.