Merge branch 'dvbsi++' of coolstreamtech.de:cst-public-gui-neutrino into dvbsi++

This commit is contained in:
[CST] Focus
2012-07-13 13:38:10 +04:00
9 changed files with 110 additions and 142 deletions

View File

@@ -1892,18 +1892,18 @@ void CAudioPlayerGui::paintItemID3DetailsLine (int pos)
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 4, ypos2+RADIUS_MID, 4, fh /*m_info_height*/, col1);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a+1, 4, ypos2a - ypos1a-1, col1);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a, 3, ypos2a - ypos1a+3, col1);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 15, ypos1a, 11, 4, col1);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 15, ypos2a, 11, 4, col1);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a, 12, 3, col1);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos2a, 12, 3, col1);
// 2. col small line
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 4, ypos2+RADIUS_MID, 1, fh /*m_info_height*/, col2);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a+1, 1, ypos2a - ypos1a + 4-1, col2);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16+3, ypos1a+3, 1, ypos2a - ypos1a-3, col2);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos1a, 12, 1, col2);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 12, ypos2a, 8, 1, col2);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16+3, ypos1a+3, 12-3, 1, col2);
m_frameBuffer->paintBoxRel(xpos + ConnectLineBox_Width - 16, ypos2a+3, 12, 1, col2);
// -- small Frame around infobox
m_frameBuffer->paintBoxFrame(m_x, ypos2, m_width, m_info_height, 2, col1, RADIUS_MID);

View File

@@ -222,14 +222,14 @@ void CBEChannelWidget::paintItem2DetailsLine (int pos, int /*ch_index*/)
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-4, ypos2+7, 4,info_height-14, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-4, ypos2+7, 1,info_height-14, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a+1, 4,ypos2a-ypos1a-1, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a+1, 1,ypos2a-ypos1a+4-1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 3,ypos2a-ypos1a+3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16+3, ypos1a+3, 1,ypos2a-ypos1a-3, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-15, ypos1a, 11,4, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 12,1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 12,3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16+3, ypos1a+3, 12-3,1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-15, ypos2a, 11,4, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-12, ypos2a, 8,1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos2a, 12,3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos2a+3, 12,1, col2);
frameBuffer->paintBoxFrame(x, ypos2, width, info_height, 2, col1, RADIUS_LARGE);
}

View File

@@ -845,10 +845,6 @@ int CChannelList::show()
res = bouquetList->exec(true);
printf("CChannelList:: bouquetList->exec res %d\n", res);
}
#if 0
/* FIXME call this somewhere after show */
CVFD::getInstance()->setMode(CVFD::MODE_TVRADIO);
#endif
this->new_mode_active = 0;
if(NeutrinoMessages::mode_ts == CNeutrinoApp::getInstance()->getMode())
@@ -1187,6 +1183,7 @@ int CChannelList::numericZap(int key)
channelList->adjustToChannelID(orgList->getActiveChannel_ChannelID(), false);
this->frameBuffer->paintBackground();
res = channelList->exec();
CVFD::getInstance()->setMode(CVFD::MODE_TVRADIO);
}
delete channelList;
return res;
@@ -1205,6 +1202,7 @@ int CChannelList::numericZap(int key)
if (channelList->getSize() != 0) {
this->frameBuffer->paintBackground();
res = channelList->exec();
CVFD::getInstance()->setMode(CVFD::MODE_TVRADIO);
}
delete channelList;
}
@@ -1581,16 +1579,16 @@ void CChannelList::paintItem2DetailsLine (int pos, int /*ch_index*/)
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-4, ypos2+7, 1,info_height-14, col2);
/* vertical connect line */
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a+1, 4,ypos2a-ypos1a-1, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a+1, 1,ypos2a-ypos1a+4-1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 3,ypos2a-ypos1a+3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16+3, ypos1a+3, 1,ypos2a-ypos1a-3, col2);
/* vertical item line */
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-15, ypos1a, 11,4, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 12,1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 12,3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16+3, ypos1a+3, 12-3,1, col2);
/* vertical info line */
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-15, ypos2a, 11,4, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-12, ypos2a, 8,1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos2a, 12,3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos2a+3, 12,1, col2);
// frameBuffer->paintBoxRel(x, ypos2, width, info_height, col1, RADIUS_LARGE);
frameBuffer->paintBoxFrame(x, ypos2, width, info_height, 2, col1, RADIUS_LARGE);

View File

@@ -142,10 +142,48 @@ int CNetworkServiceSetup::showNetworkServiceSetup()
CNetworkService * items[SERVICE_COUNT];
//telnetd used inetd
bool useinetd = false;
char line[256];
FILE* fd = fopen("/etc/inetd.conf", "r");
if(fd)
{
while(!feof(fd))
{
fgets(line, 255, fd);
{
if (strstr(line, "telnetd") != NULL)
{
useinetd = true;
break;
}
}
}
fclose(fd);
}
//set active when found
int active;
for(unsigned i = 0; i < SERVICE_COUNT; i++) {
items[i] = new CNetworkService(services[i].cmd, services[i].options);
services[i].enabled = items[i]->Enabled();
CMenuOptionChooser * mc = new CMenuOptionChooser(services[i].name.c_str(), &services[i].enabled, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true, items[i], CRCInput::convertDigitToKey(shortcut++), "");
std::string execute1 = "/bin/" + services[i].cmd;
std::string execute2 = "/sbin/" + services[i].cmd;
active = false;
if ( !(access(execute1.c_str(), F_OK)) || !(access(execute2.c_str(), F_OK)) )
active = true;
if ( (services[i].name == "Telnet") && useinetd)
active = false;
CMenuOptionChooser * mc = new CMenuOptionChooser(services[i].name.c_str(), &services[i].enabled, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, active, items[i], CRCInput::convertDigitToKey(shortcut), "");
if (active)
shortcut++;
mc->setHint(services[i].icon, services[i].hint);
setup->addItem(mc);
}

View File

@@ -1097,7 +1097,7 @@ printf("paintHint: icon %s text %s\n", item->hintIcon.c_str(), g_Locale->getText
int ypos2a = ypos2 + (hint_height/2)-2;
int markh = hint_height > rad*2 ? hint_height - rad*2 : hint_height;
int imarkh = iheight/2;
int imarkh = iheight/2+1;
int imarkoff = iheight/4;
/* horizontal item mark - */
@@ -1109,16 +1109,16 @@ printf("paintHint: icon %s text %s\n", item->hintIcon.c_str(), g_Locale->getText
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-4, ypos2+rad, 1 , markh, col2);
/* vertical connect line [ */
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a+1, 4, ypos2a-ypos1a-1, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a+1, 1, ypos2a-ypos1a+4-1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 3, ypos2a-ypos1a+3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16+3, ypos1a+3, 1, ypos2a-ypos1a-3, col2);
/* vertical item line | */
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-15, ypos1a, 11, 4, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 12, 1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos1a, 12, 3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16+3, ypos1a+3, 12-3, 1, col2);
/* vertical info line | */
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-15, ypos2a, 11, 4, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-12, ypos2a, 8, 1, col2);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos2a, 12, 3, col1);
frameBuffer->paintBoxRel(xpos+ConnectLineBox_Width-16, ypos2a+3, 12, 1, col2);
/* box shadow */
frameBuffer->paintBoxRel(x+SHADOW_OFFSET, ypos2+SHADOW_OFFSET, width + sb_width, hint_height, COL_MENUCONTENTDARK_PLUS_0, rad);