Maps a combination of keys or buttons to a command. More...
#include <Binding.hpp>
Public Member Functions | |
Binding (const Combo &combo, int command) | |
Binding (const Combo &combo, int command, float arg) | |
Binding (const Combo &combo, int command, GLuint *arg) | |
float | getArgument () const |
Combo & | getCombo () |
int | getCommand () const |
bool | hasArgument () const |
string | toString () const |
Static Protected Member Functions | |
static void | load () |
Static Protected Attributes | |
static map< int, string > | names |
static bool | loaded = false |
Private Attributes | |
bool | hasArg |
Combo | combo |
int | command |
unsigned int * | argi |
float | argf |
Maps a combination of keys or buttons to a command.
Binding | ( | const Combo & | combo, | |
int | command | |||
) |
Creates a binding for a command with no argument.
Binding | ( | const Combo & | combo, | |
int | command, | |||
float | argument | |||
) |
Creates a binding for a command with a floating-point argument.
Binding | ( | const Combo & | combo, | |
int | command, | |||
GLuint * | argument | |||
) |
Creates a binding for a command with an unsigned integer argument.
float getArgument | ( | ) | const |
Returns the value of the binding's argument.
void load | ( | ) | [inline, static, protected] |
Initializes the formatted names of triggers.
string toString | ( | ) | const |