Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

ButtonRegistry Class Reference

#include <buttonRegistry.h>

List of all members.

Public Member Functions

bool register_button (ButtonHandle &button_handle, const string &name, char ascii_equivalent= '\0')
ButtonHandle find_ascii_button (char ascii_equivalent) const
INLINE string get_name (ButtonHandle button) const
void write (ostream &out) const

Static Public Member Functions

INLINE ButtonRegistry * ptr ()

Public Attributes

PUBLISHED __pad0__: ButtonHandle get_button(const string &name)

Private Types

typedef pvector< RegistryNode * > HandleRegistry
typedef pmap< string, RegistryNode * > NameRegistry

Private Member Functions

 ButtonRegistry ()
RegistryNodelook_up (ButtonHandle button) const

Static Private Member Functions

void init_global_pointer ()

Private Attributes

HandleRegistry _handle_registry
NameRegistry _name_registry

Static Private Attributes

ButtonRegistry * _global_pointer = NULL


Member Typedef Documentation

typedef pvector<RegistryNode *> ButtonRegistry::HandleRegistry [private]
 

Definition at line 72 of file buttonRegistry.h.

typedef pmap<string, RegistryNode *> ButtonRegistry::NameRegistry [private]
 

Definition at line 75 of file buttonRegistry.h.


Constructor & Destructor Documentation

ButtonRegistry::ButtonRegistry  )  [private]
 

Definition at line 179 of file buttonRegistry.cxx.

References _handle_registry, and NULL.


Member Function Documentation

ButtonHandle ButtonRegistry::find_ascii_button char  ascii_equivalent  )  const
 

Definition at line 138 of file buttonRegistry.cxx.

References _handle_registry, ButtonHandle::none(), and NULL.

Referenced by KeyboardButton::ascii_key().

INLINE string ButtonRegistry::get_name ButtonHandle  button  )  const
 

void ButtonRegistry::init_global_pointer  )  [static, private]
 

Definition at line 198 of file buttonRegistry.cxx.

References _global_pointer.

ButtonRegistry::RegistryNode * ButtonRegistry::look_up ButtonHandle  button  )  const [private]
 

Definition at line 209 of file buttonRegistry.cxx.

References _handle_registry, ButtonHandle::_index, and NULL.

INLINE ButtonRegistry* ButtonRegistry::ptr  )  [static]
 

Referenced by KeyboardButton::ascii_key(), KeyboardButton::init_keyboard_buttons(), and MouseButton::init_mouse_buttons().

bool ButtonRegistry::register_button ButtonHandle button_handle,
const string &  name,
char  ascii_equivalent = '\0'
 

Definition at line 46 of file buttonRegistry.cxx.

References ButtonRegistry::RegistryNode::_handle, _handle_registry, ButtonHandle::_index, ButtonRegistry::RegistryNode::_name, _name_registry, index, and NULL.

Referenced by KeyboardButton::init_keyboard_buttons(), and MouseButton::init_mouse_buttons().

void ButtonRegistry::write ostream &  out  )  const
 

Definition at line 152 of file buttonRegistry.cxx.

References _handle_registry, _name_registry, and NULL.


Member Data Documentation

PUBLISHED ButtonRegistry::__pad0__
 

Definition at line 52 of file buttonRegistry.h.

ButtonRegistry * ButtonRegistry::_global_pointer = NULL [static, private]
 

Definition at line 29 of file buttonRegistry.cxx.

Referenced by init_global_pointer().

HandleRegistry ButtonRegistry::_handle_registry [private]
 

Definition at line 73 of file buttonRegistry.h.

Referenced by ButtonRegistry(), find_ascii_button(), look_up(), register_button(), and write().

NameRegistry ButtonRegistry::_name_registry [private]
 

Definition at line 76 of file buttonRegistry.h.

Referenced by register_button(), and write().


The documentation for this class was generated from the following files:
Generated on Fri Apr 18 00:11:28 2003 for Panda by doxygen1.3