Export (0) Print
Expand All

Selecting Child Objects

Clients call the IAccessible::accSelect method to modify selection or keyboard focus among the children in an object. The SELFLAG Constants specified with the call define the operation to perform.

If IAccessible::accSelect is called with the SELFLAG_TAKEFOCUS flag on a child object that has an HWND, the flag takes effect only if the object's parent has the focus.

Performing Complex Selection Operations

The following describes which SELFLAG values to specify when calling IAccessible::accSelect to perform complex selection operations.

Dd373632.wedge(en-us,VS.85).gifTo simulate a click

Dd373632.wedge(en-us,VS.85).gifTo select a target item by simulating CTRL + click

Dd373632.wedge(en-us,VS.85).gifTo cancel selection of a target item by simulating CTRL + click

Dd373632.wedge(en-us,VS.85).gifTo simulate SHIFT + click

Dd373632.wedge(en-us,VS.85).gifTo select a range of objects and put focus on the last object

  1. Specify SELFLAG_TAKEFOCUS on the starting object to set the selection anchor.
  2. Call IAccessible::accSelect again and specify SELFLAG_EXTENDSELECTION | SELFLAG_TAKEFOCUS on the last object.

Dd373632.wedge(en-us,VS.85).gifTo deselect all objects

  1. Specify SELFLAG_TAKESELECTION on any object. This flag deselects all selected objects except the one just selected.
  2. Call IAccessible::accSelect again and specify SELFLAG_REMOVESELECTION on the remaining object.

 

 

Community Additions

ADD
Show:
© 2014 Microsoft