mirror of
git://projects.qi-hardware.com/gmenu2x.git
synced 2024-12-27 12:18:57 +02:00
The ButtonBox now features a clear() function which empties the list of buttons.
This commit is contained in:
parent
6ac012348d
commit
fdee206d93
@ -10,8 +10,7 @@ ButtonBox::ButtonBox(GMenu2X *gmenu2x) : gmenu2x(gmenu2x)
|
||||
|
||||
ButtonBox::~ButtonBox()
|
||||
{
|
||||
for (ButtonList::const_iterator it = buttons.begin(); it != buttons.end(); ++it)
|
||||
delete *it;
|
||||
clear();
|
||||
}
|
||||
|
||||
void ButtonBox::add(Button *button)
|
||||
@ -19,6 +18,11 @@ void ButtonBox::add(Button *button)
|
||||
buttons.push_back(button);
|
||||
}
|
||||
|
||||
void ButtonBox::clear()
|
||||
{
|
||||
buttons.clear();
|
||||
}
|
||||
|
||||
void ButtonBox::paint(unsigned int posX)
|
||||
{
|
||||
for (ButtonList::const_iterator it = buttons.begin(); it != buttons.end(); ++it)
|
||||
|
@ -13,6 +13,7 @@ public:
|
||||
~ButtonBox();
|
||||
|
||||
void add(Button *button);
|
||||
void clear();
|
||||
|
||||
void paint(unsigned int posX);
|
||||
void handleTS();
|
||||
|
Loading…
Reference in New Issue
Block a user