You.i Engine
CYIBackButtonHandler Class Reference

Detailed Description

Intercepts the system back button notification.

This class provides an interface for listening for system back button pressed events and handling them as needed within the applications.

NotifyBackButtonPressed can be attached to a platform's back button pressed event which will notify all registered listeners that the system back button has been pressed and handle this event accordingly. The registered listeners are maintained in a static vector.

See also
CYIBackButtonHandler::Listener

#include <input/YiBackButtonHandler.h>

Classes

class  Listener
 Implement this interface to provide custom behaviour when the system back button is pressed. More...
 

Static Public Member Functions

static bool NotifyBackButtonPressed ()
 
static void AddListener (Listener *pListener)
 
static void RemoveListener (Listener *pListener)
 
static void RemoveAllListeners ()
 

Member Function Documentation

◆ AddListener()

static void CYIBackButtonHandler::AddListener ( Listener pListener)
static

Adds a listener to be notified when the back button is pressed.

◆ NotifyBackButtonPressed()

static bool CYIBackButtonHandler::NotifyBackButtonPressed ( )
static

This should be attached to the systems back button pressed event to notify the application of a system back button pressed event. This will trigger OnBackButtonPressed on all listeners added.

◆ RemoveAllListeners()

static void CYIBackButtonHandler::RemoveAllListeners ( )
static

Removes all listeners.

See also
RemoveListener

◆ RemoveListener()

static void CYIBackButtonHandler::RemoveListener ( Listener pListener)
static

Removes a listener from being notified when the back button is pressed.


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