Package AccessEngine :: Package AEAccAdapters :: Package ATSPI :: Module PopupAdapter :: Class PopupMenuEventHandlerAdapter
[hide private]
[frames] | no frames]

Class PopupMenuEventHandlerAdapter

source code

??-162 --+
         |
        PopupMenuEventHandlerAdapter

Overrides DefaultEventHandlerAdapter to avoid generating focus events on selection. Expects the subject to be a raw pyatspi.Accessibility.Accessible.

Adapts accessibles with ROLE_MENU.

Instance Methods [hide private]
tuple of AEEvent
_handleFocusEvent(self, event, **kwargs)
Creates an AEEvent.FocusChange indicating that the accessible being adapted has gained the focus.
source code
Static Methods [hide private]
boolean
when(subject)
Tests if the given subject can be adapted by this class.
source code
Class Variables [hide private]
  provides = [IEventHandler]
Method Details [hide private]

when(subject)
Static Method

source code 
Tests if the given subject can be adapted by this class.
Parameters:
  • subject (AEPor) - AEPor containing an accessible to test
Returns: boolean
True when the subject meets the condition named in the docstring for this class, False otherwise

_handleFocusEvent(self, event, **kwargs)

source code 
Creates an AEEvent.FocusChange indicating that the accessible being adapted has gained the focus. Also creates a AEEvent.SelectorChange. These two AEEvents will be posted by the caller.
Parameters:
  • event (pyatspi.event.Event) - Raw focus change event
  • kwargs (dictionary) - Parameters to be passed to any created AEEvent
Returns: tuple of AEEvent
AEEvent.FocusChange and AEEvent.SelectorChange