mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-28 07:51:19 +02:00
-add rec icon
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@707 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
@@ -162,7 +162,7 @@ void CImageInfo::paint_pig(int px, int py, int w, int h)
|
|||||||
void CImageInfo::paintLine(int xpos, int font, const char* text)
|
void CImageInfo::paintLine(int xpos, int font, const char* text)
|
||||||
{
|
{
|
||||||
char buf[100];
|
char buf[100];
|
||||||
sprintf((char*) buf, "%s", text);
|
snprintf((char*) buf,sizeof(buf), "%s", text);
|
||||||
//g_Font[font]->RenderString(xpos, ypos, width-10, buf, COL_MENUCONTENT, 0, true);
|
//g_Font[font]->RenderString(xpos, ypos, width-10, buf, COL_MENUCONTENT, 0, true);
|
||||||
g_Font[font]->RenderString(xpos, ypos, width-10, buf, COL_INFOBAR, 0, true);
|
g_Font[font]->RenderString(xpos, ypos, width-10, buf, COL_INFOBAR, 0, true);
|
||||||
}
|
}
|
||||||
@@ -197,7 +197,7 @@ void CImageInfo::paint()
|
|||||||
|
|
||||||
static CFlashVersionInfo versionInfo(version);
|
static CFlashVersionInfo versionInfo(version);
|
||||||
const char * releaseCycle = versionInfo.getReleaseCycle();
|
const char * releaseCycle = versionInfo.getReleaseCycle();
|
||||||
sprintf((char*) imagedate, "%s %s", versionInfo.getDate(), versionInfo.getTime());
|
snprintf((char*) imagedate,sizeof(imagedate), "%s %s", versionInfo.getDate(), versionInfo.getTime());
|
||||||
|
|
||||||
ypos += iheight;
|
ypos += iheight;
|
||||||
paintLine(xpos , font_info, g_Locale->getText(LOCALE_IMAGEINFO_IMAGE));
|
paintLine(xpos , font_info, g_Locale->getText(LOCALE_IMAGEINFO_IMAGE));
|
||||||
|
@@ -312,20 +312,23 @@ void CInfoViewer::showRecordIcon (const bool show)
|
|||||||
{
|
{
|
||||||
recordModeActive = CNeutrinoApp::getInstance ()->recordingstatus || shift_timer;
|
recordModeActive = CNeutrinoApp::getInstance ()->recordingstatus || shift_timer;
|
||||||
if (recordModeActive) {
|
if (recordModeActive) {
|
||||||
int ChanName_X = BoxStartX + ChanWidth + 20;
|
int icon_w = 0,icon_h = 0;
|
||||||
|
frameBuffer->getIconSize(autoshift ? NEUTRINO_ICON_AUTO_SHIFT : NEUTRINO_ICON_REC, &icon_w, &icon_h);
|
||||||
|
int chanH = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getHeight ();
|
||||||
|
int ChanName_X = BoxStartX + ChanWidth + SHADOW_OFFSET;
|
||||||
|
const int icon_space = 3, box_len = 300, box_pos= 12;
|
||||||
if (show) {
|
if (show) {
|
||||||
int chanH = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getHeight ();
|
|
||||||
frameBuffer->paintIcon (autoshift ? NEUTRINO_ICON_AUTO_SHIFT : NEUTRINO_ICON_BUTTON_RED, ChanName_X, BoxStartY + 12);
|
|
||||||
if (!autoshift && !shift_timer) {
|
if (!autoshift && !shift_timer) {
|
||||||
frameBuffer->paintBoxRel (ChanName_X + 28 + SHADOW_OFFSET, BoxStartY + 12 + SHADOW_OFFSET, 300, chanH, COL_INFOBAR_SHADOW_PLUS_0);
|
frameBuffer->paintBoxRel (ChanName_X + SHADOW_OFFSET, BoxStartY + box_pos + SHADOW_OFFSET, box_len, chanH, COL_INFOBAR_SHADOW_PLUS_0);
|
||||||
frameBuffer->paintBoxRel (ChanName_X + 28, BoxStartY + 12, 300, chanH, COL_INFOBAR_PLUS_0);
|
frameBuffer->paintBoxRel (ChanName_X , BoxStartY + box_pos , box_len, chanH, COL_INFOBAR_PLUS_0);
|
||||||
g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString (ChanName_X + 30, BoxStartY + 12 + chanH, 300, ext_channel_name.c_str (), COL_INFOBAR, 0, true);
|
g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->RenderString (ChanName_X +icon_w + (icon_space*2), BoxStartY + box_pos + chanH, box_len, ext_channel_name.c_str (), COL_INFOBAR, 0, true);
|
||||||
} else
|
} else{
|
||||||
frameBuffer->paintBackgroundBoxRel (ChanName_X + 28, BoxStartY + 12, 300 + SHADOW_OFFSET, chanH + SHADOW_OFFSET);
|
frameBuffer->paintBackgroundBoxRel (ChanName_X , BoxStartY + box_pos, box_len + SHADOW_OFFSET, chanH + SHADOW_OFFSET);
|
||||||
|
}
|
||||||
|
frameBuffer->paintIcon (autoshift ? NEUTRINO_ICON_AUTO_SHIFT : NEUTRINO_ICON_REC, ChanName_X + icon_space, BoxStartY + box_pos + (chanH - icon_h)/2);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
int icon_w = 0,icon_h = 0;
|
frameBuffer->paintBoxRel (ChanName_X + icon_space, BoxStartY + box_pos + (chanH - icon_h)/2, icon_w, icon_h,COL_INFOBAR_PLUS_0);
|
||||||
frameBuffer->getIconSize(autoshift ? NEUTRINO_ICON_AUTO_SHIFT : NEUTRINO_ICON_BUTTON_RED, &icon_w, &icon_h);
|
|
||||||
frameBuffer->paintBackgroundBoxRel (ChanName_X, BoxStartY + 12, icon_w, icon_h);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -88,6 +88,7 @@
|
|||||||
#define NEUTRINO_ICON_QUESTION "question"
|
#define NEUTRINO_ICON_QUESTION "question"
|
||||||
#define NEUTRINO_ICON_RADIOMODE "radiomode"
|
#define NEUTRINO_ICON_RADIOMODE "radiomode"
|
||||||
#define NEUTRINO_ICON_RECORDING "recording"
|
#define NEUTRINO_ICON_RECORDING "recording"
|
||||||
|
#define NEUTRINO_ICON_REC "rec"
|
||||||
#define NEUTRINO_ICON_SETTINGS "settings"
|
#define NEUTRINO_ICON_SETTINGS "settings"
|
||||||
#define NEUTRINO_ICON_SHELL "shell"
|
#define NEUTRINO_ICON_SHELL "shell"
|
||||||
#define NEUTRINO_ICON_STREAMING "streaming"
|
#define NEUTRINO_ICON_STREAMING "streaming"
|
||||||
|
Reference in New Issue
Block a user