diff --git a/src/gui/bedit/bouqueteditor_bouquets.cpp b/src/gui/bedit/bouqueteditor_bouquets.cpp index c87e2171f..5f15679eb 100644 --- a/src/gui/bedit/bouqueteditor_bouquets.cpp +++ b/src/gui/bedit/bouqueteditor_bouquets.cpp @@ -202,7 +202,8 @@ int CBEBouquetWidget::exec(CMenuTarget* parent, const std::string & /*actionKey* if (parent) parent->hide(); - width = w_max (500, 0); + int fw = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getWidth(); + width = w_max (52 * fw, 20); height = h_max (440, 50); listmaxshow = (height-theight-0)/iheight; height = theight+0+listmaxshow*iheight; // recalc height diff --git a/src/gui/bedit/bouqueteditor_channels.cpp b/src/gui/bedit/bouqueteditor_channels.cpp index cb4976ba8..b4641d767 100644 --- a/src/gui/bedit/bouqueteditor_channels.cpp +++ b/src/gui/bedit/bouqueteditor_channels.cpp @@ -181,8 +181,8 @@ int CBEChannelWidget::exec(CMenuTarget* parent, const std::string & /*actionKey* if (parent) parent->hide(); - - width = w_max (500, 0); + int fw = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getWidth(); + width = w_max (52 * fw, 20); height = h_max (440, 50); listmaxshow = (height-theight-0)/iheight; height = theight+0+listmaxshow*iheight; // recalc height diff --git a/src/gui/bouquetlist.cpp b/src/gui/bouquetlist.cpp index 2826fa8ac..d236bd7cf 100644 --- a/src/gui/bouquetlist.cpp +++ b/src/gui/bouquetlist.cpp @@ -296,7 +296,7 @@ int CBouquetList::show(bool bShowChannelList) CVFD::getInstance()->setMode(CVFD::MODE_MENU_UTF8, ""); fheight = g_Font[SNeutrinoSettings::FONT_TYPE_CHANNELLIST]->getHeight(); - width = w_max (g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getWidth()*53, 20);//500 + width = w_max (g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getWidth()*52, 20);//500 height = h_max (16 * fheight, 40); /* assuming all color icons must have same size */ diff --git a/src/gui/eventlist.cpp b/src/gui/eventlist.cpp index e22b8fb39..d5ac71dc8 100644 --- a/src/gui/eventlist.cpp +++ b/src/gui/eventlist.cpp @@ -215,13 +215,13 @@ int EventList::exec(const t_channel_id channel_id, const std::string& channelnam neutrino_msg_t msg; neutrino_msg_data_t data; bool in_search = 0; - - width = w_max (680, 20); - height = h_max (560, 20); + int fw = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getWidth(); + int fh = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getHeight(); + width = w_max (75 * fw, 20); + height = h_max (25 * fh, 20); iheight = 30; // info bar height (see below, hard coded at this time) - int fh = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getHeight(); if(iheight < fh) iheight = fh; diff --git a/src/gui/filebrowser.cpp b/src/gui/filebrowser.cpp index 21d7282fb..71460172f 100644 --- a/src/gui/filebrowser.cpp +++ b/src/gui/filebrowser.cpp @@ -1395,14 +1395,18 @@ const struct button_label FileBrowserFilterButton[2] = void CFileBrowser::paintFoot() { + const struct button_label FileBrowserButtons2[3] = +{ + { NEUTRINO_ICON_BUTTON_OKAY , LOCALE_FILEBROWSER_SELECT }, + { NEUTRINO_ICON_BUTTON_HELP , sortByNames[g_settings.filebrowser_sortmethod] }, + { NEUTRINO_ICON_BUTTON_MUTE_SMALL, LOCALE_FILEBROWSER_DELETE }, +}; + int dx = (width-20) / 4; //Second Line (bottom, top) int by2 = y + height - (foheight - 4); - int fh = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getHeight(); int iw = 0, ih = 0; frameBuffer->getIconSize(NEUTRINO_ICON_BUTTON_RED, &iw, &ih); - int ty2 = by2 + fh -(fh-ih)/2; - const int noname = 35; //Background frameBuffer->paintBoxRel(x, y + height - (2 * foheight ), width, (2 * foheight ), COL_INFOBAR_SHADOW_PLUS_1, RADIUS_MID, CORNER_BOTTOM); @@ -1419,19 +1423,18 @@ void CFileBrowser::paintFoot() //OK-Button if( (filelist[selected].getType() != CFile::FILE_UNKNOWN) || (S_ISDIR(filelist[selected].Mode)) ) { - frameBuffer->paintIcon(NEUTRINO_ICON_BUTTON_OKAY, x +10 , by2 - 3); - g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString(x + noname, ty2, dx - noname, g_Locale->getText(LOCALE_FILEBROWSER_SELECT), COL_INFOBAR /*_SHADOW_PLUS_1*/, 0, true); // UTF-8 + ::paintButtons(frameBuffer, g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL], g_Locale, x + 10 , by2, dx, 1,&(FileBrowserButtons2[0])); } //?-Button - frameBuffer->paintIcon(NEUTRINO_ICON_BUTTON_HELP, x + 10 +(1 * dx), by2 - 3); - g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString(x + noname + (1 * dx), ty2, dx - noname, g_Locale->getText(sortByNames[g_settings.filebrowser_sortmethod]), COL_INFOBAR /*_SHADOW_PLUS_1*/, 0, true); // UTF-8 + ::paintButtons(frameBuffer, g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL], g_Locale, x + 10 + dx , by2, dx, 1,&(FileBrowserButtons2[1])); + //Mute-Button if (strncmp(Path.c_str(), VLC_URI, strlen(VLC_URI)) != 0) { //Not in vlc mode - frameBuffer->paintIcon(NEUTRINO_ICON_BUTTON_MUTE_SMALL, x + 10 + (2 * dx), by2 - 3); - g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString(x + noname + (2 * dx), ty2, dx - noname, g_Locale->getText(LOCALE_FILEBROWSER_DELETE), COL_INFOBAR /*_SHADOW_PLUS_1*/, 0, true); // UTF-8 + ::paintButtons(frameBuffer, g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL], g_Locale, x + 10 + (dx * 2) , by2, dx, 1,&(FileBrowserButtons2[2])); + } if(m_SMSKeyInput.getOldKey()!=0)