15 #ifndef CLIENTBUTTONDEVICE_H 16 #define CLIENTBUTTONDEVICE_H 18 #include "pandabase.h" 20 #include "clientDevice.h" 22 #include "buttonHandle.h" 23 #include "buttonEvent.h" 24 #include "buttonEventList.h" 25 #include "pointerTo.h" 42 INLINE
int get_num_buttons()
const;
44 INLINE
void set_button_map(
int index,
ButtonHandle button);
47 void set_button_state(
int index,
bool down);
48 INLINE
bool get_button_state(
int index)
const;
49 INLINE
bool is_button_known(
int index)
const;
53 virtual void output(ostream &out)
const;
54 virtual void write(ostream &out,
int indent_level = 0)
const;
56 void output_buttons(ostream &out)
const;
57 void write_buttons(ostream &out,
int indent_level)
const;
60 void ensure_button_index(
int index);
86 static void init_type() {
87 ClientDevice::init_type();
88 register_type(_type_handle,
"ClientButtonDevice",
89 ClientDevice::get_class_type());
92 return get_class_type();
94 virtual TypeHandle force_init_type() {init_type();
return get_class_type();}
98 friend class ButtonState;
101 #include "clientButtonDevice.I"
An abstract base class for a family of client device interfaces–including trackers, buttons, dials, and other analog inputs.
TypeHandle is the identifier used to differentiate C++ class types.
Any of a number of different devices that might be attached to a ClientBase, including trackers...