GOG GALAXY SDK Documentation
IListenerRegistrar Class Referenceabstract

The class that enables and disables global registration of the instances of specific listeners. More...

#include <IListenerRegistrar.h>

Public Member Functions

virtual void Register (ListenerType listenerType, IGalaxyListener *listener)=0
 Globally registers a callback listener that inherits from IGalaxyListener and is of any of the standard listener types specified in ListenerType. More...
 
virtual void Unregister (ListenerType listenerType, IGalaxyListener *listener)=0
 Unregisters a listener previously globally registered with Register() or registered for specific action. More...
 

Detailed Description

The class that enables and disables global registration of the instances of specific listeners.

You can either use it explicitly, or implicitly by inheriting from a self-registering basic listener of desired type.

Member Function Documentation

◆ Register()

virtual void Register ( ListenerType  listenerType,
IGalaxyListener listener 
)
pure virtual

Globally registers a callback listener that inherits from IGalaxyListener and is of any of the standard listener types specified in ListenerType.

Remarks
Call Unregister() for all registered listeners before calling Shutdown().
Parameters
[in]listenerTypeThe type of the listener. A value of ListenerType.
[in]listenerThe specific listener of the specified type.

◆ Unregister()

virtual void Unregister ( ListenerType  listenerType,
IGalaxyListener listener 
)
pure virtual

Unregisters a listener previously globally registered with Register() or registered for specific action.

Call Unregister() unregisters listener from all pending asynchonous calls.

Parameters
[in]listenerTypeThe type of the listener. A value of ListenerType.
[in]listenerThe specific listener of the specified type.