neutrino: improve epgplus scalability

git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@237 e54a6e83-5905-42d5-8d5c-058d10e6a962


Origin commit data
------------------
Branch: ni/coolstream
Commit: 6843cdf969
Author: Stefan Seyfried <seife@tuxbox-git.slipkontur.de>
Date: 2010-01-31 (Sun, 31 Jan 2010)



------------------
This commit was generated by Migit
This commit is contained in:
Stefan Seyfried
2010-01-31 15:42:10 +00:00
parent 7863caeeb8
commit c26c998bd9

View File

@@ -80,8 +80,9 @@ static EpgPlus::FontSetting fontSettingTable[] = {
{ EpgPlus::EPGPlus_footer_fontbuttons, "Regular", 16 }, { EpgPlus::EPGPlus_footer_fontbuttons, "Regular", 16 },
}; };
/* negative size means "screen width in percent" */
static EpgPlus::SizeSetting sizeSettingTable[] = { static EpgPlus::SizeSetting sizeSettingTable[] = {
{EpgPlus::EPGPlus_channelentry_width, 100}, {EpgPlus::EPGPlus_channelentry_width, -15 }, /* 15 percent of screen width */
{EpgPlus::EPGPlus_channelentry_separationlineheight, 2}, {EpgPlus::EPGPlus_channelentry_separationlineheight, 2},
{EpgPlus::EPGPlus_slider_width, 15}, {EpgPlus::EPGPlus_slider_width, 15},
{EpgPlus::EPGPlus_horgap1_height, 4}, {EpgPlus::EPGPlus_horgap1_height, 4},
@@ -654,7 +655,10 @@ void EpgPlus::init ()
} }
for (size_t i = 0; i < NumberOfSizeSettings; ++i) { for (size_t i = 0; i < NumberOfSizeSettings; ++i) {
sizes[i] = sizeSettingTable[i].size; int size = sizeSettingTable[i].size;
if (size < 0) /* size < 0 == width in percent x -1 */
size = usableScreenWidth * size / -100;
sizes[i] = size;
} }
Header::init (); Header::init ();