#include <glui.h>
Inherits GLUI_Control.
Public Member Functions | |
int | mouse_down_handler (int local_x, int local_y) |
int | mouse_up_handler (int local_x, int local_y, bool inside) |
int | mouse_held_down_handler (int local_x, int local_y, bool inside) |
int | key_handler (unsigned char key, int modifiers) |
void | draw (int x, int y) |
void | draw_pressed (void) |
void | draw_text (int sunken) |
void | update_size (void) |
GLUI_Button (GLUI_Node *parent, const char *name, int id=-1, GLUI_CB cb=GLUI_CB()) | |
GLUI_Button (void) | |
Public Attributes | |
bool | currently_inside |
Protected Member Functions | |
void | common_init (void) |
GLUI_Button::GLUI_Button | ( | GLUI_Node * | parent, | |
const char * | name, | |||
int | id = -1 , |
|||
GLUI_CB | cb = GLUI_CB() | |||
) |
Create a new button.
parent | The panel our object is inside; or the main GLUI object. | |
name | The text inside the button. | |
id | Optional ID number, to pass to the optional callback function. | |
callback | Optional callback function, taking either the int ID or control. |
GLUI_Button::GLUI_Button | ( | void | ) | [inline] |
void GLUI_Button::common_init | ( | void | ) | [inline, protected] |
void GLUI_Button::draw | ( | int | x, | |
int | y | |||
) | [virtual] |
Implements GLUI_Control.
void GLUI_Button::draw_pressed | ( | void | ) |
void GLUI_Button::draw_text | ( | int | sunken | ) |
int GLUI_Button::key_handler | ( | unsigned char | key, | |
int | modifiers | |||
) | [virtual] |
Reimplemented from GLUI_Control.
int GLUI_Button::mouse_down_handler | ( | int | local_x, | |
int | local_y | |||
) | [virtual] |
Reimplemented from GLUI_Control.
int GLUI_Button::mouse_held_down_handler | ( | int | local_x, | |
int | local_y, | |||
bool | inside | |||
) | [virtual] |
Reimplemented from GLUI_Control.
int GLUI_Button::mouse_up_handler | ( | int | local_x, | |
int | local_y, | |||
bool | inside | |||
) | [virtual] |
Reimplemented from GLUI_Control.
void GLUI_Button::update_size | ( | void | ) | [virtual] |
Reimplemented from GLUI_Control.