Panda3D
Public Member Functions | Static Public Member Functions

ButtonRegistry Class Reference

The ButtonRegistry class maintains all the assigned ButtonHandles in a given system. More...

List of all members.

Public Member Functions

ButtonHandle findAsciiButton (char ascii_equivalent)
 Finds a ButtonHandle in the registry matching the indicated ASCII equivalent character.
ButtonHandle getButton (string name)
 Finds a ButtonHandle in the registry matching the indicated name.
 write (ostream out)

Static Public Member Functions

static ButtonRegistry ptr ()
 Returns the pointer to the global ButtonRegistry object.

Detailed Description

The ButtonRegistry class maintains all the assigned ButtonHandles in a given system.

There should be only one ButtonRegistry class during the lifetime of the application.


Member Function Documentation

ButtonHandle findAsciiButton ( char  ascii_equivalent)

Finds a ButtonHandle in the registry matching the indicated ASCII equivalent character.

If there is no such ButtonHandle, returns ButtonHandle.none().

ButtonHandle getButton ( string  name)

Finds a ButtonHandle in the registry matching the indicated name.

If there is no such ButtonHandle, registers a new one and returns it.

static ButtonRegistry ptr ( ) [static]

Returns the pointer to the global ButtonRegistry object.

write ( ostream  out)
 All Classes Namespaces Functions Variables Enumerations Enumerator Properties