#include <dropdown.h>
A ListModel provides the contents of the drop down. To be able to use DropDown you must give DropDown an implemented ListModel which represents your list.
Definition at line 37 of file dropdown.h.
Public Member Functions | |
DropDown (gcn::ListModel *listModel=NULL) | |
Contructor. | |
~DropDown () | |
void | draw (gcn::Graphics *graphics) |
void | drawFrame (gcn::Graphics *graphics) |
void | keyPressed (gcn::KeyEvent &keyEvent) |
void | mouseWheelMovedUp (gcn::MouseEvent &mouseEvent) |
void | mouseWheelMovedDown (gcn::MouseEvent &mouseEvent) |
Protected Member Functions | |
void | drawButton (gcn::Graphics *graphics) |
Draws the button with the little down arrow. | |
Static Protected Attributes | |
static int | instances = 0 |
static Image * | buttons [2][2] |
static ImageRect | skin |
static float | mAlpha = 1.0 |
DropDown::DropDown | ( | gcn::ListModel * | listModel = NULL |
) |
Contructor.
listModel | the ListModel to use. | |
scrollArea | the ScrollArea to use. | |
listBox | the listBox to use. |
Definition at line 45 of file dropdown.cpp.
DropDown::~DropDown | ( | ) |
Definition at line 99 of file dropdown.cpp.
void DropDown::draw | ( | gcn::Graphics * | graphics | ) |
Definition at line 116 of file dropdown.cpp.
void DropDown::drawFrame | ( | gcn::Graphics * | graphics | ) |
Definition at line 176 of file dropdown.cpp.
void DropDown::keyPressed | ( | gcn::KeyEvent & | keyEvent | ) |
Definition at line 194 of file dropdown.cpp.
void DropDown::mouseWheelMovedUp | ( | gcn::MouseEvent & | mouseEvent | ) |
Definition at line 226 of file dropdown.cpp.
void DropDown::mouseWheelMovedDown | ( | gcn::MouseEvent & | mouseEvent | ) |
Definition at line 232 of file dropdown.cpp.
void DropDown::drawButton | ( | gcn::Graphics * | graphics | ) | [protected] |
Draws the button with the little down arrow.
graphics | a Graphics object to draw with. |
Definition at line 185 of file dropdown.cpp.
int DropDown::instances = 0 [static, protected] |
Definition at line 75 of file dropdown.h.
Image * DropDown::buttons [static, protected] |
Definition at line 76 of file dropdown.h.
ImageRect DropDown::skin [static, protected] |
Definition at line 77 of file dropdown.h.
float DropDown::mAlpha = 1.0 [static, protected] |
Definition at line 78 of file dropdown.h.