From 42c7d6db83d815f6b8522342f3dc66e5de58f4a1 Mon Sep 17 00:00:00 2001 From: Stefan Seyfried Date: Sun, 3 Jan 2010 16:34:52 +0000 Subject: [PATCH] epgview: fix 'color direction' of progressbar git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@142 e54a6e83-5905-42d5-8d5c-058d10e6a962 Origin commit data ------------------ Branch: ni/coolstream Commit: https://github.com/neutrino-images/ni-neutrino/commit/aac9e518c0365eccfc36458c82283453748b125a Author: Stefan Seyfried Date: 2010-01-03 (Sun, 03 Jan 2010) ------------------ This commit was generated by Migit --- src/gui/epgview.cpp | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/src/gui/epgview.cpp b/src/gui/epgview.cpp index 3cc0ca072..71af0a2cd 100644 --- a/src/gui/epgview.cpp +++ b/src/gui/epgview.cpp @@ -127,8 +127,14 @@ CEpgData::CEpgData() void CEpgData::start() { - ox = w_max (MAX_W * (bigFonts ? BIG_FONT_FAKTOR : 1), 0); - oy = h_max (MAX_H * (bigFonts ? BIG_FONT_FAKTOR : 1), 0); + /* This defines the size of the EPG window. We leave 35 pixels left and right, + * 25 pixels top and bottom. It adjusts itself to the "visible screen" settings + */ + ox = w_max (1280, 70); + oy = h_max (720, 50 + 30); // 30 for the bottom button box. + +// ox = w_max (MAX_W * (bigFonts ? BIG_FONT_FAKTOR : 1), 0); +// oy = h_max (MAX_H * (bigFonts ? BIG_FONT_FAKTOR : 1), 0); sx = getScreenStartX( ox ); topheight = g_Font[SNeutrinoSettings::FONT_TYPE_EPG_TITLE]->getHeight(); @@ -145,6 +151,7 @@ void CEpgData::start() oy = botboxheight+medlinecount*medlineheight; // recalculate //FIXME sy = getScreenStartY(oy- topboxheight); toph = topboxheight; +fprintf(stderr, "CEpgData::start ox: %d oy: %d sx: %d sy: %d xmax: %d ymax: %d\n", ox, oy, sy, sy, w_max(9999,0), h_max(9999,0)); } void CEpgData::addTextToArray(const std::string & text) // UTF-8 @@ -627,7 +634,7 @@ int CEpgData::show(const t_channel_id channel_id, unsigned long long a_id, time_ if ( epg_done!= -1 ) { int pbx = sx + 10 + widthl + 10 + ((ox-104-widthr-widthl-10-10-20)>>1); - CProgressBar pb(pb_blink); + CProgressBar pb(pb_blink, -1, -1, 30, 100, 70, true); pb.paintProgressBarDefault(pbx, sy+oy-height, 104, height-6, epg_done, 104); } @@ -667,7 +674,7 @@ int CEpgData::show(const t_channel_id channel_id, unsigned long long a_id, time_ if (data == g_InfoViewer->lcdUpdateTimer) { GetEPGData(channel_id, id, &startzeit ); if ( epg_done!= -1 ) { - CProgressBar pb(pb_blink); + CProgressBar pb(pb_blink, -1, -1, 30, 100, 70, true); int pbx = sx + 10 + widthl + 10 + ((ox-104-widthr-widthl-10-10-20)>>1); pb.paintProgressBarDefault(pbx, sy+oy-height, 104, height-6, epg_done, 104); }