widget/listbox.cpp use paintButtons in foot

Origin commit data
------------------
Branch: ni/coolstream
Commit: 682b4b141c
Author: Jacek Jendrzej <overx300@gmail.com>
Date: 2014-05-09 (Fri, 09 May 2014)


------------------
No further description and justification available within origin commit message!

------------------
This commit was generated by Migit
This commit is contained in:
Jacek Jendrzej
2014-05-09 22:02:53 +02:00
parent 06269ca967
commit 3cf91e6a4e

View File

@@ -26,6 +26,7 @@
#endif #endif
#include <gui/widget/listbox.h> #include <gui/widget/listbox.h>
#include <gui/widget/buttons.h>
#include <global.h> #include <global.h>
#include <neutrino.h> #include <neutrino.h>
@@ -88,22 +89,16 @@ void CListBox::paintHead()
void CListBox::paintFoot() void CListBox::paintFoot()
{ {
int ButtonWidth = width / 4; const struct button_label ListButtons[] =
//frameBuffer->paintBoxRel(x,y+height, width,ButtonHeight, COL_MENUHEAD_PLUS_0); {
frameBuffer->paintBoxRel(x, y+height, width, ButtonHeight, COL_MENUHEAD_PLUS_0, RADIUS_LARGE, CORNER_BOTTOM);//round { NEUTRINO_ICON_BUTTON_OKAY, LOCALE_CHANNELLIST_EDIT },
frameBuffer->paintHLine(x, x+width, y, COL_INFOBAR_SHADOW_PLUS_0); { NEUTRINO_ICON_BUTTON_RED, LOCALE_BOUQUETEDITOR_ADD},
{ NEUTRINO_ICON_BUTTON_GREEN, LOCALE_BOUQUETEDITOR_DELETE},
{ NEUTRINO_ICON_BUTTON_HOME, LOCALE_BOUQUETEDITOR_RETURN }
};
const short numbuttons = sizeof(ListButtons)/sizeof(ListButtons[0]);
::paintButtons(x, y + height-ButtonHeight, width, numbuttons, ListButtons, width, ButtonHeight);
frameBuffer->paintIcon(NEUTRINO_ICON_BUTTON_OKAY, x+width- 4* ButtonWidth+ 8, y+height+1);
g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString(x+width- 4* ButtonWidth+ 38, y+height+24 - 2, width, "edit", COL_INFOBAR_TEXT);
frameBuffer->paintIcon(NEUTRINO_ICON_BUTTON_GREEN, x+width- 3* ButtonWidth+ 8, y+height+4);
g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString(x+width- 3* ButtonWidth+ 29, y+height+24 - 2, width- 26, "add", COL_INFOBAR_TEXT);
frameBuffer->paintIcon(NEUTRINO_ICON_BUTTON_RED, x+width- 2* ButtonWidth+ 8, y+height+4);
g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString(x+width- 2* ButtonWidth+ 29, y+height+24 - 2, width- 26, "remove", COL_INFOBAR_TEXT);
frameBuffer->paintIcon(NEUTRINO_ICON_BUTTON_HOME, x+width - ButtonWidth+ 8, y+height+1);
g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString(x+width - ButtonWidth+ 38, y+height+24 - 2, width, "ready", COL_INFOBAR_TEXT);
} }
void CListBox::paintItem(int pos) void CListBox::paintItem(int pos)