Loading...
Searching...
No Matches
juce::AccessibilityActions Class Reference

Detailed Description

A simple wrapper for building a collection of supported accessibility actions and corresponding callbacks for a UI element.

Pass one of these when constructing an AccessibilityHandler to enable users to interact with a UI element via the supported actions.


The documentation for this class was generated from the following file:

Public Member Functions

 AccessibilityActions ()=default
 Constructor.
AccessibilityActionsaddAction (AccessibilityActionType type, std::function< void()> actionCallback)
 Adds an action.
bool contains (AccessibilityActionType type) const
 Returns true if the specified action is supported.
bool invoke (AccessibilityActionType type) const
 If an action has been registered for the provided action type, invokes the action and returns true.

Constructors and Destructors

◆ AccessibilityActions()

juce::AccessibilityActions::AccessibilityActions ( )
default

Constructor.

Creates a default AccessibilityActions object with no action callbacks.

Referenced by addAction().

Member Functions

◆ addAction()

AccessibilityActions & juce::AccessibilityActions::addAction ( AccessibilityActionType type,
std::function< void()> actionCallback )
inline

Adds an action.

When the user performs this action with an accessibility client actionCallback will be called.

Returns a reference to itself so that several calls can be chained.

References AccessibilityActions().

◆ contains()

bool juce::AccessibilityActions::contains ( AccessibilityActionType type) const
inline

Returns true if the specified action is supported.

◆ invoke()

bool juce::AccessibilityActions::invoke ( AccessibilityActionType type) const
inline

If an action has been registered for the provided action type, invokes the action and returns true.

Otherwise, returns false.

linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram