mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-28 07:51:19 +02:00
Mark unused vars as comment
git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@104 e54a6e83-5905-42d5-8d5c-058d10e6a962
This commit is contained in:
@@ -86,7 +86,7 @@ THandleStatus CControlAPI::Hook_SendResponse(CyhookHandler *hh)
|
||||
{
|
||||
hh->status = HANDLED_NONE;
|
||||
|
||||
// log_level_printfX(4,"CControlAPI hook start url:%s\n",hh->UrlData["url"].c_str());
|
||||
// log_level_printfX(4,"CControlAPI hook start url:%s\n",hh->UrlData["url"].c_str());
|
||||
init(hh);
|
||||
|
||||
if(hh->UrlData["path"] == "/control/"
|
||||
@@ -94,9 +94,9 @@ THandleStatus CControlAPI::Hook_SendResponse(CyhookHandler *hh)
|
||||
Execute(hh);
|
||||
if(hh->UrlData["path"] == "/fb/") // fb-compatibility for timer-calls
|
||||
compatibility_Timer(hh);
|
||||
// log_level_printfX(4,"CControlAPI hook ende status:%d\n",(int)hh->status);
|
||||
// log_level_printfX(5,"CControlAPI hook result:%s\n",hh->yresult.c_str());
|
||||
|
||||
// log_level_printfX(4,"CControlAPI hook ende status:%d\n",(int)hh->status);
|
||||
// log_level_printfX(5,"CControlAPI hook result:%s\n",hh->yresult.c_str());
|
||||
|
||||
return hh->status;
|
||||
}
|
||||
|
||||
@@ -107,7 +107,7 @@ THandleStatus CControlAPI::Hook_SendResponse(CyhookHandler *hh)
|
||||
//-------------------------------------------------------------------------
|
||||
void CControlAPI::compatibility_Timer(CyhookHandler *hh)
|
||||
{
|
||||
log_level_printf(4,"CControlAPI Compatibility Timer Start url:%s\n",hh->UrlData["url"].c_str());
|
||||
log_level_printf(4,"CControlAPI Compatibility Timer Start url:%s\n",hh->UrlData["url"].c_str());
|
||||
if(NeutrinoAPI->Timerd->isTimerdAvailable() && hh->ParamList.size() > 0)
|
||||
{
|
||||
if(hh->ParamList["action"] == "remove")
|
||||
@@ -190,7 +190,7 @@ void CControlAPI::Execute(CyhookHandler *hh)
|
||||
std::string yresult;
|
||||
std::string filename = hh->UrlData["filename"];
|
||||
|
||||
log_level_printf(4,"ControlAPI.Execute filename:(%s)\n",filename.c_str());
|
||||
log_level_printf(4,"ControlAPI.Execute filename:(%s)\n",filename.c_str());
|
||||
// tolower(filename)
|
||||
for(unsigned int i = 0; i < filename.length(); i++)
|
||||
filename[i] = tolower(filename[i]);
|
||||
@@ -233,9 +233,9 @@ void CControlAPI::Execute(CyhookHandler *hh)
|
||||
return;
|
||||
else
|
||||
{
|
||||
(this->*yCgiCallList[index].pfunc)(hh);
|
||||
(this->*yCgiCallList[index].pfunc)(hh);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//=============================================================================
|
||||
@@ -269,7 +269,7 @@ void CControlAPI::TimerCGI(CyhookHandler *hh)
|
||||
else
|
||||
hh->SendError();
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
SendTimers(hh);
|
||||
@@ -694,7 +694,7 @@ static const struct key keynames[] = {
|
||||
{"KEY_RECORD", KEY_RECORD},
|
||||
{"KEY_STOP", KEY_STOP},
|
||||
{"KEY_PLAY", KEY_PLAY}
|
||||
};
|
||||
};
|
||||
|
||||
// The code here is based on rcsim. Thx Carjay!
|
||||
void CControlAPI::RCEmCGI(CyhookHandler *hh)
|
||||
@@ -709,7 +709,7 @@ void CControlAPI::RCEmCGI(CyhookHandler *hh)
|
||||
if (!strcmp(keyname.c_str(), keynames[i].name))
|
||||
sendcode = keynames[i].code;
|
||||
}
|
||||
|
||||
|
||||
if (sendcode == -1) {
|
||||
printf("[nhttpd] Key %s not found\n", keyname.c_str());
|
||||
hh->SendError();
|
||||
@@ -746,7 +746,7 @@ void CControlAPI::RCEmCGI(CyhookHandler *hh)
|
||||
return;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
if (rc_send(evd, sendcode, KEY_RELEASED)<0){
|
||||
perror("writing 'KEY_RELEASED' event failed");
|
||||
close(evd);
|
||||
@@ -810,7 +810,7 @@ void CControlAPI::VideoOutputCGI(CyhookHandler *hh)
|
||||
else {
|
||||
hh->SendError();
|
||||
}
|
||||
|
||||
|
||||
NeutrinoAPI->Controld->setVideoOutput(videooutput);
|
||||
hh->SendOk();
|
||||
}
|
||||
@@ -833,8 +833,8 @@ void CControlAPI::VCROutputCGI(CyhookHandler *hh)
|
||||
}
|
||||
|
||||
// S-Video on VCR only possible when S-Video or CVBS on TV; enforce
|
||||
if (vcroutput == CControldClient::VIDEOOUTPUT_SVIDEO
|
||||
&& (NeutrinoAPI->Controld->getVideoOutput() != CControldClient::VIDEOOUTPUT_COMPOSITE)
|
||||
if (vcroutput == CControldClient::VIDEOOUTPUT_SVIDEO
|
||||
&& (NeutrinoAPI->Controld->getVideoOutput() != CControldClient::VIDEOOUTPUT_COMPOSITE)
|
||||
&& (NeutrinoAPI->Controld->getVideoOutput() != CControldClient::VIDEOOUTPUT_SVIDEO)) {
|
||||
hh->SendError();
|
||||
return;
|
||||
@@ -868,7 +868,7 @@ void CControlAPI::ScartModeCGI(CyhookHandler *hh)
|
||||
void CControlAPI::VolumeCGI(CyhookHandler *hh)
|
||||
{
|
||||
if (hh->ParamList.empty()) //without param: show actual volumen
|
||||
hh->printf("%d", NeutrinoAPI->Controld->getVolume());
|
||||
hh->printf("%d", NeutrinoAPI->Controld->getVolume());
|
||||
else if (hh->ParamList["1"].compare("mute") == 0)
|
||||
{
|
||||
NeutrinoAPI->Zapit->muteAudio(true);
|
||||
@@ -1099,7 +1099,7 @@ void CControlAPI::EpgCGI(CyhookHandler *hh)
|
||||
{
|
||||
hh->SetHeader(HTTP_OK, "text/xml; charset=UTF-8");
|
||||
t_channel_id channel_id = (t_channel_id)-1;
|
||||
|
||||
|
||||
if (!(hh->ParamList["channelid"].empty()))
|
||||
{
|
||||
sscanf(hh->ParamList["channelid"].c_str(),
|
||||
@@ -1120,12 +1120,12 @@ void CControlAPI::EpgCGI(CyhookHandler *hh)
|
||||
PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS
|
||||
"</channel_id>\r\n", channel_id);
|
||||
hh->printf("<channel_name><![CDATA[%s]]></channel_name>\r\n", NeutrinoAPI->GetServiceName(channel_id).c_str());
|
||||
|
||||
|
||||
// max = maximal output items
|
||||
int max = -1;
|
||||
if (!(hh->ParamList["max"].empty()))
|
||||
max = atoi( hh->ParamList["max"].c_str() );
|
||||
|
||||
|
||||
// stoptime = maximal output items until starttime >= stoptime
|
||||
long stoptime = -1;
|
||||
if (!(hh->ParamList["stoptime"].empty()))
|
||||
@@ -1154,11 +1154,11 @@ void CControlAPI::EpgCGI(CyhookHandler *hh)
|
||||
hh->printf("\t<stop_t>%s</stop_t>\r\n", zbuffer);
|
||||
hh->printf("\t<duration_min>%d</duration_min>\r\n", (int)(eventIterator->duration/60));
|
||||
hh->printf("\t<description><![CDATA[%s]]></description>\r\n", eventIterator->description.c_str());
|
||||
|
||||
|
||||
if (!(hh->ParamList["details"].empty()))
|
||||
{
|
||||
CShortEPGData epg;
|
||||
|
||||
|
||||
//if (NeutrinoAPI->Sectionsd->getEPGidShort(eventIterator->eventID,&epg))
|
||||
if (sectionsd_getEPGidShort(eventIterator->eventID,&epg))
|
||||
{
|
||||
@@ -1234,7 +1234,7 @@ void CControlAPI::ZaptoCGI(CyhookHandler *hh)
|
||||
{
|
||||
for(unsigned int i=0;i< desc.size();i++)
|
||||
{
|
||||
t_channel_id sub_channel_id =
|
||||
t_channel_id sub_channel_id =
|
||||
CREATE_CHANNEL_ID_FROM_SERVICE_ORIGINALNETWORK_TRANSPORTSTREAM_ID(
|
||||
desc[i].serviceId, desc[i].originalNetworkId, desc[i].transportStreamId);
|
||||
hh->printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS
|
||||
@@ -1287,7 +1287,7 @@ void CControlAPI::StartPluginCGI(CyhookHandler *hh)
|
||||
}
|
||||
else
|
||||
hh->SendError();
|
||||
|
||||
|
||||
}
|
||||
else
|
||||
hh->SendError();
|
||||
@@ -1687,7 +1687,7 @@ void CControlAPI::YWeb_SendRadioStreamingPid(CyhookHandler *hh)
|
||||
}
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
std::string CControlAPI::YexecuteScript(CyhookHandler *hh, std::string cmd)
|
||||
std::string CControlAPI::YexecuteScript(CyhookHandler */*hh*/, std::string cmd)
|
||||
{
|
||||
std::string script, para, result;
|
||||
bool found = false;
|
||||
@@ -1707,7 +1707,7 @@ std::string CControlAPI::YexecuteScript(CyhookHandler *hh, std::string cmd)
|
||||
char cwd[255];
|
||||
getcwd(cwd, 254);
|
||||
|
||||
for (unsigned int i=0;i<PLUGIN_DIR_COUNT && !found;i++)
|
||||
for (unsigned int i=0;i<PLUGIN_DIR_COUNT && !found;i++)
|
||||
{
|
||||
fullfilename = PLUGIN_DIRS[i]+"/"+script;
|
||||
FILE *test =fopen(fullfilename.c_str(),"r"); // use fopen: popen does not work
|
||||
@@ -1781,7 +1781,7 @@ void CControlAPI::doNewTimer(CyhookHandler *hh)
|
||||
// Alarm Time - Format exact! HH:MM
|
||||
if(hh->ParamList["alTime"] != "")
|
||||
sscanf(hh->ParamList["alTime"].c_str(),"%2d.%2d",&(alarmTime->tm_hour), &(alarmTime->tm_min));
|
||||
|
||||
|
||||
correctTime(alarmTime);
|
||||
alarmTimeT = mktime(alarmTime);
|
||||
announceTimeT = alarmTimeT;
|
||||
@@ -1790,7 +1790,7 @@ void CControlAPI::doNewTimer(CyhookHandler *hh)
|
||||
// Stop Time - Format exact! HH:MM
|
||||
if(hh->ParamList["stTime"] != "")
|
||||
sscanf(hh->ParamList["stTime"].c_str(),"%2d.%2d",&(stopTime->tm_hour), &(stopTime->tm_min));
|
||||
|
||||
|
||||
// Stop Date - Format exact! DD.MM.YYYY
|
||||
if(hh->ParamList["stDate"] != "")
|
||||
if(sscanf(hh->ParamList["stDate"].c_str(),"%2d.%2d.%4d",&(stopTime->tm_mday), &(stopTime->tm_mon), &(stopTime->tm_year)) == 3)
|
||||
@@ -1838,16 +1838,16 @@ void CControlAPI::doNewTimer(CyhookHandler *hh)
|
||||
correctTime(stopTime);
|
||||
stopTimeT = mktime(stopTime);
|
||||
}
|
||||
|
||||
if(announceTimeT != 0)
|
||||
|
||||
if(announceTimeT != 0)
|
||||
announceTimeT -= 60;
|
||||
|
||||
|
||||
CTimerd::CTimerEventTypes type;
|
||||
if(hh->ParamList["type"] != "")
|
||||
type = (CTimerd::CTimerEventTypes) atoi(hh->ParamList["type"].c_str());
|
||||
else // default is: record
|
||||
type = CTimerd::TIMER_RECORD;
|
||||
|
||||
|
||||
// repeat
|
||||
if(hh->ParamList["repcount"] != "")
|
||||
{
|
||||
@@ -1875,7 +1875,7 @@ void CControlAPI::doNewTimer(CyhookHandler *hh)
|
||||
&eventinfo.channel_id);
|
||||
else
|
||||
eventinfo.channel_id = NeutrinoAPI->ChannelNameToChannelId(hh->ParamList["channel_name"]);
|
||||
|
||||
|
||||
void *data=NULL;
|
||||
if(type == CTimerd::TIMER_RECORD)
|
||||
announceTimeT-=120;
|
||||
@@ -1929,7 +1929,7 @@ void CControlAPI::doNewTimer(CyhookHandler *hh)
|
||||
timerlist.clear();
|
||||
NeutrinoAPI->Timerd->getTimerList(timerlist);
|
||||
CTimerd::TimerList::iterator timer = timerlist.begin();
|
||||
|
||||
|
||||
// Look for Recording Safety Timers too
|
||||
time_t real_alarmTimeT = alarmTimeT;
|
||||
if(eventinfo.recordingSafety)
|
||||
@@ -1938,7 +1938,7 @@ void CControlAPI::doNewTimer(CyhookHandler *hh)
|
||||
NeutrinoAPI->Timerd->getRecordingSafety(pre,post);
|
||||
real_alarmTimeT -= pre;
|
||||
}
|
||||
|
||||
|
||||
for(; timer != timerlist.end();timer++)
|
||||
if(timer->alarmTime == real_alarmTimeT)
|
||||
{
|
||||
@@ -1979,7 +1979,7 @@ void CControlAPI::saveBouquetCGI(CyhookHandler *hh)
|
||||
void CControlAPI::moveBouquetCGI(CyhookHandler *hh)
|
||||
{
|
||||
if (hh->ParamList["selected"] != "" && (
|
||||
hh->ParamList["action"] == "up" ||
|
||||
hh->ParamList["action"] == "up" ||
|
||||
hh->ParamList["action"] == "down"))
|
||||
{
|
||||
int selected = atoi(hh->ParamList["selected"].c_str());
|
||||
@@ -2026,9 +2026,9 @@ void CControlAPI::addBouquetCGI(CyhookHandler *hh)
|
||||
//-------------------------------------------------------------------------
|
||||
void CControlAPI::renameBouquetCGI(CyhookHandler *hh)
|
||||
{
|
||||
if (hh->ParamList["selected"] != "")
|
||||
if (hh->ParamList["selected"] != "")
|
||||
{
|
||||
if (hh->ParamList["nameto"] != "")
|
||||
if (hh->ParamList["nameto"] != "")
|
||||
{
|
||||
if (NeutrinoAPI->Zapit->existsBouquet((hh->ParamList["nameto"]).c_str()) == -1)
|
||||
{
|
||||
@@ -2064,7 +2064,7 @@ void CControlAPI::changeBouquetCGI(CyhookHandler *hh)
|
||||
&delta) > 0)
|
||||
{
|
||||
NeutrinoAPI->Zapit->addChannelToBouquet(selected - 1, channel_id);
|
||||
bchannels += (delta + 1); // skip the separating ',', too
|
||||
bchannels += (delta + 1); // skip the separating ',', too
|
||||
}
|
||||
|
||||
NeutrinoAPI->Zapit->renumChannellist();
|
||||
@@ -2090,17 +2090,17 @@ void CControlAPI::build_live_url(CyhookHandler *hh)
|
||||
{
|
||||
std::string xpids,port,yresult;
|
||||
int mode = NeutrinoAPI->Zapit->getMode();
|
||||
|
||||
|
||||
if ( mode == CZapitClient::MODE_TV)
|
||||
{
|
||||
CZapitClient::responseGetPIDs pids;
|
||||
int apid=0,apid_no=0,apid_idx=0;
|
||||
pids.PIDs.vpid=0;
|
||||
|
||||
|
||||
if(hh->ParamList["audio_no"] !="")
|
||||
apid_no = atoi(hh->ParamList["audio_no"].c_str());
|
||||
NeutrinoAPI->Zapit->getPIDS(pids);
|
||||
|
||||
|
||||
if( apid_no < (int)pids.APIDs.size())
|
||||
apid_idx=apid_no;
|
||||
if(!pids.APIDs.empty())
|
||||
@@ -2111,11 +2111,11 @@ void CControlAPI::build_live_url(CyhookHandler *hh)
|
||||
{
|
||||
CZapitClient::responseGetPIDs pids;
|
||||
int apid=0;
|
||||
|
||||
|
||||
NeutrinoAPI->Zapit->getPIDS(pids);
|
||||
if(!pids.APIDs.empty())
|
||||
apid = pids.APIDs[0].pid;
|
||||
|
||||
|
||||
//xpids = string_printf("0x%04x",apid);
|
||||
xpids = string_printf("0x%04x,0x%04x",pids.PIDs.pmtpid,apid);
|
||||
}
|
||||
|
@@ -86,7 +86,7 @@ void CLCDAPI::LockDisplay(int plock)
|
||||
}
|
||||
}
|
||||
|
||||
void CLCDAPI::DrawLine(int x1, int y1, int x2, int y2, int col)
|
||||
void CLCDAPI::DrawLine(int /*x1*/, int /*y1*/, int /*x2*/, int /*y2*/, int /*col*/)
|
||||
{
|
||||
#if HAVE_LCD
|
||||
int color=(col==0)?(CLCDDisplay::PIXEL_OFF):((col==2)?(CLCDDisplay::PIXEL_INV):(CLCDDisplay::PIXEL_ON));
|
||||
@@ -94,7 +94,7 @@ void CLCDAPI::DrawLine(int x1, int y1, int x2, int y2, int col)
|
||||
#endif
|
||||
}
|
||||
|
||||
void CLCDAPI::DrawRect(int x1, int y1, int x2, int y2, int coll, int colf)
|
||||
void CLCDAPI::DrawRect(int /*x1*/, int /*y1*/, int /*x2*/, int /*y2*/, int /*coll*/, int /*colf*/)
|
||||
{
|
||||
#if HAVE_LCD
|
||||
int colorl=(coll==0)?(CLCDDisplay::PIXEL_OFF):((coll==2)?(CLCDDisplay::PIXEL_INV):(CLCDDisplay::PIXEL_ON));
|
||||
@@ -103,7 +103,7 @@ void CLCDAPI::DrawRect(int x1, int y1, int x2, int y2, int coll, int colf)
|
||||
#endif
|
||||
}
|
||||
|
||||
void CLCDAPI::DrawText(int px, int py, int psize, int pcolor, int pfont, char *pmsg)
|
||||
void CLCDAPI::DrawText(int /*px*/, int /*py*/, int /*psize*/, int /*pcolor*/, int /*pfont*/, char */*pmsg*/)
|
||||
{
|
||||
#if HAVE_LCD
|
||||
int color=(pcolor==0)?(CLCDDisplay::PIXEL_OFF):((pcolor==2)?(CLCDDisplay::PIXEL_INV):(CLCDDisplay::PIXEL_ON));
|
||||
@@ -116,7 +116,7 @@ void CLCDAPI::DrawText(int px, int py, int psize, int pcolor, int pfont, char *p
|
||||
#endif
|
||||
}
|
||||
|
||||
bool CLCDAPI::ShowPng(char *filename)
|
||||
bool CLCDAPI::ShowPng(char */*filename*/)
|
||||
{
|
||||
#if HAVE_LCD
|
||||
return display.load_png(filename);
|
||||
@@ -124,13 +124,13 @@ bool CLCDAPI::ShowPng(char *filename)
|
||||
return 0;
|
||||
}
|
||||
|
||||
void CLCDAPI::ShowRaw(int xpos, int ypos, int xsize, int ysize, char *ascreen)
|
||||
void CLCDAPI::ShowRaw(int /*xpos*/, int /*ypos*/, int /*xsize*/, int /*ysize*/, char */*ascreen*/)
|
||||
{
|
||||
#if HAVE_LCD
|
||||
int sbyte,dbit,dxpos,dypos,wasinc=0,gotval;
|
||||
char *sptr=ascreen;
|
||||
raw_display_t rscreen;
|
||||
|
||||
|
||||
display.dump_screen(&rscreen);
|
||||
gotval=sscanf(sptr,"%d",&sbyte);
|
||||
for(dypos=ypos; gotval && (dypos<(ypos+ysize)); dypos++)
|
||||
@@ -173,7 +173,7 @@ void CLCDAPI::ShowRaw(int xpos, int ypos, int xsize, int ysize, char *ascreen)
|
||||
display.load_screen(&rscreen);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
// Konstruktor und destruktor
|
||||
@@ -183,7 +183,7 @@ CLCDAPI::CLCDAPI()
|
||||
{
|
||||
#if HAVE_LCD
|
||||
// int i;
|
||||
|
||||
|
||||
|
||||
// display = new CLCDDisplay();
|
||||
fontRenderer = new LcdFontRenderClass(&display);
|
||||
|
@@ -136,7 +136,7 @@ void CNeutrinoAPI::UpdateBouquets(void)
|
||||
{
|
||||
#if 0
|
||||
BouquetList.clear();
|
||||
Zapit->getBouquets(BouquetList, true, true);
|
||||
Zapit->getBouquets(BouquetList, true, true);
|
||||
|
||||
for (unsigned int i = 1; i <= BouquetList.size(); i++)
|
||||
UpdateBouquet(i);
|
||||
@@ -164,7 +164,7 @@ void CNeutrinoAPI::ZapToChannelId(t_channel_id channel_id)
|
||||
//printf("Kanal ist aktuell\n");
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
if (Zapit->zapTo_serviceID(channel_id) != CZapitClient::ZAP_INVALID_PARAM)
|
||||
Sectionsd->setServiceChanged(channel_id&0xFFFFFFFFFFFFULL, false);
|
||||
}
|
||||
@@ -259,10 +259,10 @@ bool CNeutrinoAPI::GetChannelEvents(void)
|
||||
CChannelEventList::iterator eventIterator;
|
||||
|
||||
ChannelListEvents.clear();
|
||||
|
||||
|
||||
if (eList.begin() == eList.end())
|
||||
return false;
|
||||
|
||||
|
||||
for (eventIterator = eList.begin(); eventIterator != eList.end(); eventIterator++)
|
||||
ChannelListEvents[(*eventIterator).get_channel_id()] = &(*eventIterator);
|
||||
|
||||
@@ -290,19 +290,19 @@ std::string CNeutrinoAPI::GetServiceName(t_channel_id channel_id)
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
|
||||
CZapitClient::BouquetChannelList *CNeutrinoAPI::GetBouquet(unsigned int BouquetNr, int Mode)
|
||||
CZapitClient::BouquetChannelList *CNeutrinoAPI::GetBouquet(unsigned int /*BouquetNr*/, int /*Mode*/)
|
||||
{
|
||||
//FIXME
|
||||
printf("CNeutrinoAPI::GetChannelList still used !\n");
|
||||
return NULL;
|
||||
#if 0
|
||||
int mode;
|
||||
|
||||
|
||||
if (Mode == CZapitClient::MODE_CURRENT)
|
||||
mode = Zapit->getMode();
|
||||
else
|
||||
mode = Mode;
|
||||
|
||||
|
||||
if (mode == CZapitClient::MODE_TV)
|
||||
return &TVBouquetsList[BouquetNr];
|
||||
else
|
||||
@@ -312,19 +312,19 @@ CZapitClient::BouquetChannelList *CNeutrinoAPI::GetBouquet(unsigned int BouquetN
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
|
||||
CZapitClient::BouquetChannelList *CNeutrinoAPI::GetChannelList(int Mode)
|
||||
CZapitClient::BouquetChannelList *CNeutrinoAPI::GetChannelList(int /*Mode*/)
|
||||
{
|
||||
//FIXME
|
||||
printf("CNeutrinoAPI::GetChannelList still used !\n");
|
||||
return NULL;
|
||||
#if 0
|
||||
int mode;
|
||||
|
||||
|
||||
if (Mode == CZapitClient::MODE_CURRENT)
|
||||
mode = Zapit->getMode();
|
||||
else
|
||||
mode = Mode;
|
||||
|
||||
|
||||
if (mode == CZapitClient::MODE_TV)
|
||||
return &TVChannelList;
|
||||
else
|
||||
@@ -334,7 +334,7 @@ CZapitClient::BouquetChannelList *CNeutrinoAPI::GetChannelList(int Mode)
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
|
||||
void CNeutrinoAPI::UpdateBouquet(unsigned int BouquetNr)
|
||||
void CNeutrinoAPI::UpdateBouquet(unsigned int /*BouquetNr*/)
|
||||
{
|
||||
#if 0 //FIXME
|
||||
TVBouquetsList[BouquetNr].clear();
|
||||
|
@@ -59,7 +59,7 @@ THandleStatus CNeutrinoYParser::Hook_SendResponse(CyhookHandler *hh)
|
||||
{
|
||||
hh->status = HANDLED_NONE;
|
||||
|
||||
// log_level_printf(4,"Neutrinoparser Hook Start url:%s\n",hh->UrlData["url"].c_str());
|
||||
// log_level_printf(4,"Neutrinoparser Hook Start url:%s\n",hh->UrlData["url"].c_str());
|
||||
init(hh);
|
||||
|
||||
CNeutrinoYParser *yP = new CNeutrinoYParser(NeutrinoAPI); // create a Session
|
||||
@@ -70,13 +70,13 @@ THandleStatus CNeutrinoYParser::Hook_SendResponse(CyhookHandler *hh)
|
||||
yP->Execute(hh);
|
||||
if(hh->status == HANDLED_NOT_IMPLEMENTED)
|
||||
hh->status = HANDLED_NONE; // y-calls can be implemented anywhere
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
delete yP;
|
||||
|
||||
// log_level_printf(4,"Neutrinoparser Hook Ende status:%d\n",(int)hh->status);
|
||||
// log_level_printf(5,"Neutrinoparser Hook Result:%s\n",hh->yresult.c_str());
|
||||
|
||||
// log_level_printf(4,"Neutrinoparser Hook Ende status:%d\n",(int)hh->status);
|
||||
// log_level_printf(5,"Neutrinoparser Hook Result:%s\n",hh->yresult.c_str());
|
||||
|
||||
return hh->status;
|
||||
}
|
||||
//-----------------------------------------------------------------------------
|
||||
@@ -147,7 +147,7 @@ std::string CNeutrinoYParser::YWeb_cgi_func(CyhookHandler *hh, std::string ycmd
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : mount_get_list
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_mount_get_list(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_mount_get_list(CyhookHandler */*hh*/, std::string /*para*/)
|
||||
{
|
||||
CConfigFile *Config = new CConfigFile(',');
|
||||
std::string ysel, ytype, yip, ylocal_dir, ydir, ynr, yresult;
|
||||
@@ -159,11 +159,11 @@ std::string CNeutrinoYParser::func_mount_get_list(CyhookHandler *hh, std::strin
|
||||
ynr=itoa(i);
|
||||
ysel = ((i==0) ? "checked=\"checked\"" : "");
|
||||
yitype = Config->getInt32("network_nfs_type_"+ynr,0);
|
||||
ytype = ( (yitype==0) ? "NFS" :((yitype==1) ? "CIFS" : "FTPFS") );
|
||||
ytype = ( (yitype==0) ? "NFS" :((yitype==1) ? "CIFS" : "FTPFS") );
|
||||
yip = Config->getString("network_nfs_ip_"+ynr,"");
|
||||
ydir = Config->getString("network_nfs_dir_"+ynr,"");
|
||||
ylocal_dir = Config->getString("network_nfs_local_dir_"+ynr,"");
|
||||
if(ydir != "")
|
||||
if(ydir != "")
|
||||
ydir="("+ydir+")";
|
||||
|
||||
yresult += string_printf("<input type='radio' name='R1' value='%d' %s />%d %s - %s %s %s<br/>",
|
||||
@@ -176,7 +176,7 @@ std::string CNeutrinoYParser::func_mount_get_list(CyhookHandler *hh, std::strin
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : mount_set_values
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_mount_set_values(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_mount_set_values(CyhookHandler *hh, std::string /*para*/)
|
||||
{
|
||||
CConfigFile *Config = new CConfigFile(',');
|
||||
std::string ynr, yresult;
|
||||
@@ -201,11 +201,11 @@ std::string CNeutrinoYParser::func_mount_set_values(CyhookHandler *hh, std::str
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get_bouquets_as_dropdown [<bouquet>] <doshowhidden>
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_bouquets_as_dropdown(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_bouquets_as_dropdown(CyhookHandler */*hh*/, std::string para)
|
||||
{
|
||||
std::string ynr, yresult, sel, nr_str, do_show_hidden;
|
||||
int nr=1;
|
||||
|
||||
|
||||
ySplitString(para," ",nr_str, do_show_hidden);
|
||||
if(nr_str != "")
|
||||
nr = atoi(nr_str.c_str());
|
||||
@@ -213,13 +213,13 @@ std::string CNeutrinoYParser::func_get_bouquets_as_dropdown(CyhookHandler *hh,
|
||||
for (int i = 0; i < (int) g_bouquetManager->Bouquets.size(); i++) {
|
||||
sel=(nr==(i+1)) ? "selected=\"selected\"" : "";
|
||||
if(!g_bouquetManager->Bouquets[i]->bHidden || do_show_hidden == "true")
|
||||
yresult += string_printf("<option value=%u %s>%s</option>\n", i + 1, sel.c_str(),
|
||||
yresult += string_printf("<option value=%u %s>%s</option>\n", i + 1, sel.c_str(),
|
||||
(encodeString(std::string(g_bouquetManager->Bouquets[i]->bFav ? g_Locale->getText(LOCALE_FAVORITES_BOUQUETNAME) :g_bouquetManager->Bouquets[i]->Name.c_str()))).c_str());
|
||||
//yresult += string_printf("<option value=%u %s>%s</option>\n", i + 1, sel.c_str(), (encodeString(std::string(g_bouquetManager->Bouquets[i]->Name.c_str()))).c_str());
|
||||
}
|
||||
#if 0
|
||||
for (unsigned int i = 0; i < NeutrinoAPI->BouquetList.size();i++)
|
||||
{
|
||||
{
|
||||
sel=(nr==(i+1)) ? "selected=\"selected\"" : "";
|
||||
if(!NeutrinoAPI->BouquetList[i].hidden || do_show_hidden == "true")
|
||||
yresult += string_printf("<option value=%u %s>%s</option>\n", (NeutrinoAPI->BouquetList[i].bouquet_nr) + 1, sel.c_str(), (encodeString(std::string(NeutrinoAPI->BouquetList[i].name))).c_str());
|
||||
@@ -232,10 +232,10 @@ std::string CNeutrinoYParser::func_get_bouquets_as_dropdown(CyhookHandler *hh,
|
||||
// y-func : get_bouquets_as_templatelist <tempalte> [~<do_show_hidden>]
|
||||
// TODO: select actual Bouquet
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_bouquets_as_templatelist(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_bouquets_as_templatelist(CyhookHandler */*hh*/, std::string para)
|
||||
{
|
||||
std::string yresult, ytemplate, do_show_hidden;
|
||||
|
||||
|
||||
ySplitString(para,"~",ytemplate, do_show_hidden);
|
||||
//ytemplate += "\n"; //FIXME add newline to printf
|
||||
for (int i = 0; i < (int) g_bouquetManager->Bouquets.size(); i++) {
|
||||
@@ -246,7 +246,7 @@ std::string CNeutrinoYParser::func_get_bouquets_as_templatelist(CyhookHandler *
|
||||
}
|
||||
#if 0
|
||||
for (unsigned int i = 0; i < NeutrinoAPI->BouquetList.size();i++)
|
||||
{
|
||||
{
|
||||
if(!NeutrinoAPI->BouquetList[i].hidden || do_show_hidden == "true")
|
||||
{
|
||||
yresult += string_printf(ytemplate.c_str(), (NeutrinoAPI->BouquetList[i].bouquet_nr) + 1, NeutrinoAPI->BouquetList[i].name);
|
||||
@@ -259,7 +259,7 @@ std::string CNeutrinoYParser::func_get_bouquets_as_templatelist(CyhookHandler *
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get_actual_bouquet_number
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_actual_bouquet_number(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_actual_bouquet_number(CyhookHandler */*hh*/, std::string /*para*/)
|
||||
{
|
||||
//CZapitClient::BouquetChannelList *bouquet;
|
||||
//int mode = CZapitClient::MODE_CURRENT;
|
||||
@@ -277,13 +277,13 @@ std::string CNeutrinoYParser::func_get_actual_bouquet_number(CyhookHandler *hh,
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get_channel_dropdown [<bouquet_nr> [<channel_id>]]
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_channels_as_dropdown(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_channels_as_dropdown(CyhookHandler */*hh*/, std::string para)
|
||||
{
|
||||
std::string abouquet, achannel_id, yresult, sel, sid;
|
||||
|
||||
|
||||
int bnumber = 1;
|
||||
int mode = CZapitClient::MODE_CURRENT;
|
||||
|
||||
|
||||
ySplitString(para," ",abouquet, achannel_id);
|
||||
if(abouquet != "")
|
||||
bnumber = atoi(abouquet.c_str());
|
||||
@@ -319,7 +319,7 @@ std::string CNeutrinoYParser::func_get_bouquets_with_epg(CyhookHandler *hh, std:
|
||||
ZapitChannelList channels;
|
||||
int num;
|
||||
int mode = NeutrinoAPI->Zapit->getMode();
|
||||
|
||||
|
||||
ySplitString(para," ",abnumber, tmp);
|
||||
if(abnumber != "")
|
||||
BouquetNr = atoi(abnumber.c_str());
|
||||
@@ -343,7 +343,7 @@ std::string CNeutrinoYParser::func_get_bouquets_with_epg(CyhookHandler *hh, std:
|
||||
CSectionsdClient::responseGetCurrentNextInfoChannelID currentNextInfo;
|
||||
std::string timestr;
|
||||
bool have_logos = false;
|
||||
|
||||
|
||||
if(hh->WebserverConfigList["ExtrasDocumentRoot"] == "web" || (access((hh->WebserverConfigList["ExtrasDocumentRoot"]+"/logos").c_str(),4)==0) )
|
||||
have_logos = true;
|
||||
|
||||
@@ -355,7 +355,7 @@ std::string CNeutrinoYParser::func_get_bouquets_with_epg(CyhookHandler *hh, std:
|
||||
#if 1
|
||||
CChannelEvent *event;
|
||||
event = NeutrinoAPI->ChannelListEvents[channel->channel_id];
|
||||
|
||||
|
||||
classname = (i++ & 1) ? 'a' : 'b';
|
||||
if (channel->channel_id == current_channel)
|
||||
classname = 'c';
|
||||
@@ -367,10 +367,10 @@ std::string CNeutrinoYParser::func_get_bouquets_with_epg(CyhookHandler *hh, std:
|
||||
PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS
|
||||
"')\"><img class=\"channel_logo\" src=\"%s/logos/"
|
||||
PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS
|
||||
".jpg\"/></a></td>", classname, channel->channel_id,
|
||||
".jpg\"/></a></td>", classname, channel->channel_id,
|
||||
(hh->WebserverConfigList["ExtrasDocumentURL"]).c_str(),
|
||||
channel->channel_id & 0xFFFFFFFFFFFFULL);
|
||||
|
||||
|
||||
/* timer slider */
|
||||
if(event && event->duration > 0)
|
||||
prozent = 100 * (time(NULL) - event->startTime) / event->duration;
|
||||
@@ -387,7 +387,7 @@ std::string CNeutrinoYParser::func_get_bouquets_with_epg(CyhookHandler *hh, std:
|
||||
, (prozent / 10) * 3
|
||||
, (10 - (prozent / 10))*3
|
||||
);
|
||||
|
||||
|
||||
/* channel name and buttons */
|
||||
yresult += string_printf("<td>\n%s<a class=\"clist\" href=\"javascript:do_zap('"
|
||||
PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS
|
||||
@@ -416,19 +416,19 @@ std::string CNeutrinoYParser::func_get_bouquets_with_epg(CyhookHandler *hh, std:
|
||||
if (sectionsd_getNVODTimesServiceKey(channel->channel_id&0xFFFFFFFFFFFFULL, nvod_list))
|
||||
{
|
||||
CZapitClient::subServiceList subServiceList;
|
||||
|
||||
|
||||
for (CSectionsdClient::NVODTimesList::iterator ni = nvod_list.begin(); ni != nvod_list.end(); ni++)
|
||||
{
|
||||
CZapitClient::commandAddSubServices cmd;
|
||||
CEPGData epg;
|
||||
|
||||
|
||||
// Byte Sequence by ntohs
|
||||
cmd.original_network_id = ntohs(ni->original_network_id);
|
||||
cmd.service_id = ntohs(ni->service_id);
|
||||
cmd.transport_stream_id = ntohs(ni->transport_stream_id);
|
||||
|
||||
t_channel_id channel_id = CREATE_CHANNEL_ID_FROM_SERVICE_ORIGINALNETWORK_TRANSPORTSTREAM_ID(cmd.service_id, cmd.original_network_id, cmd.transport_stream_id);
|
||||
|
||||
|
||||
timestr = timeString(ni->zeit.startzeit); // FIXME: time is wrong (at least on little endian)!
|
||||
|
||||
//NeutrinoAPI->Sectionsd->getActualEPGServiceKey(channel_id&0xFFFFFFFFFFFFULL, &epg); // FIXME: der scheissendreck geht nit!!!
|
||||
@@ -455,7 +455,7 @@ std::string CNeutrinoYParser::func_get_bouquets_with_epg(CyhookHandler *hh, std:
|
||||
NeutrinoAPI->Zapit->setSubServices(subServiceList);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
else if ((event = NeutrinoAPI->ChannelListEvents[channel->channel_id]))
|
||||
{
|
||||
//bool has_current_next = NeutrinoAPI->Sectionsd->getCurrentNextServiceKey(channel->channel_id&0xFFFFFFFFFFFFULL, currentNextInfo);
|
||||
@@ -488,18 +488,18 @@ std::string CNeutrinoYParser::func_get_bouquets_with_epg(CyhookHandler *hh, std:
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get_actual_channel_id
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_actual_channel_id(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_actual_channel_id(CyhookHandler */*hh*/, std::string /*para*/)
|
||||
{
|
||||
return string_printf(PRINTF_CHANNEL_ID_TYPE_NO_LEADING_ZEROS, live_channel_id /*NeutrinoAPI->Zapit->getCurrentServiceID()*/);
|
||||
}
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get_mode (returns tv|radio|unknown)
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_mode(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_mode(CyhookHandler */*hh*/, std::string /*para*/)
|
||||
{
|
||||
std::string yresult;
|
||||
int mode = NeutrinoAPI->Zapit->getMode();
|
||||
|
||||
|
||||
if ( mode == CZapitClient::MODE_TV)
|
||||
yresult = "tv";
|
||||
else if ( mode == CZapitClient::MODE_RADIO)
|
||||
@@ -512,12 +512,12 @@ std::string CNeutrinoYParser::func_get_mode(CyhookHandler *hh, std::string para
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get_video_pids (para=audio channel, returns: 0x0000,0x0000,0x0000)
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_video_pids(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_video_pids(CyhookHandler */*hh*/, std::string para)
|
||||
{
|
||||
CZapitClient::responseGetPIDs pids;
|
||||
int apid=0,apid_no=0,apid_idx=0;
|
||||
pids.PIDs.vpid=0;
|
||||
|
||||
|
||||
if(para != "")
|
||||
apid_no = atoi(para.c_str());
|
||||
NeutrinoAPI->Zapit->getPIDS(pids);
|
||||
@@ -531,15 +531,15 @@ std::string CNeutrinoYParser::func_get_video_pids(CyhookHandler *hh, std::strin
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get_radio_pids (returns: 0x0000)
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_radio_pid(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_radio_pid(CyhookHandler */*hh*/, std::string /*para*/)
|
||||
{
|
||||
CZapitClient::responseGetPIDs pids;
|
||||
int apid=0;
|
||||
|
||||
|
||||
NeutrinoAPI->Zapit->getPIDS(pids);
|
||||
if(!pids.APIDs.empty())
|
||||
apid = pids.APIDs[0].pid;
|
||||
|
||||
|
||||
return string_printf("0x%04x",apid);
|
||||
}
|
||||
|
||||
@@ -547,13 +547,13 @@ std::string CNeutrinoYParser::func_get_radio_pid(CyhookHandler *hh, std::string
|
||||
// y-func : get_audio_pids_as_dropdown (from controlapi)
|
||||
// prara: [apid] option value = apid-Value. Default apid-Index
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_audio_pids_as_dropdown(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_audio_pids_as_dropdown(CyhookHandler */*hh*/, std::string para)
|
||||
{
|
||||
std::string yresult;
|
||||
static bool init_iso=true;
|
||||
bool idx_as_id=true;
|
||||
|
||||
if(para == "apid")
|
||||
|
||||
if(para == "apid")
|
||||
idx_as_id=false;
|
||||
if(init_iso)
|
||||
{
|
||||
@@ -622,10 +622,10 @@ std::string CNeutrinoYParser::func_get_audio_pids_as_dropdown(CyhookHandler *hh
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : build umount list
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_unmount_get_list(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_unmount_get_list(CyhookHandler */*hh*/, std::string /*para*/)
|
||||
{
|
||||
std::string ysel, ymount, ylocal_dir, yfstype, ynr, yresult, mounts;
|
||||
|
||||
|
||||
std::ifstream in;
|
||||
in.open("/proc/mounts", std::ifstream::in);
|
||||
int j=0;
|
||||
@@ -650,11 +650,11 @@ std::string CNeutrinoYParser::func_unmount_get_list(CyhookHandler *hh, std::str
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : build partition list
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_partition_list(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_partition_list(CyhookHandler */*hh*/, std::string /*para*/)
|
||||
{
|
||||
std::string ysel, ymtd, yname, dummy, yresult;
|
||||
char ytmp[200];
|
||||
|
||||
|
||||
std::ifstream in;
|
||||
in.open("/proc/mtd", std::ifstream::in);
|
||||
int j=0;
|
||||
@@ -677,14 +677,14 @@ std::string CNeutrinoYParser::func_get_partition_list(CyhookHandler *hh, std::s
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get boxtypetext (Nokia, Philips, Sagem)
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_boxtype(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_boxtype(CyhookHandler */*hh*/, std::string /*para*/)
|
||||
{
|
||||
return NeutrinoAPI->Dbox_Hersteller[NeutrinoAPI->Controld->getBoxType()];
|
||||
}
|
||||
//-------------------------------------------------------------------------
|
||||
// y-func : get stream info
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_current_stream_info(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_current_stream_info(CyhookHandler *hh, std::string /*para*/)
|
||||
{
|
||||
int bitInfo[10];
|
||||
CZapitClient::CCurrentServiceInfo serviceinfo;
|
||||
@@ -701,10 +701,10 @@ std::string CNeutrinoYParser::func_get_current_stream_info(CyhookHandler *hh, s
|
||||
hh->ParamList["polarisation"] = serviceinfo.polarisation==1?"h":"v";
|
||||
hh->ParamList["ServiceName"] = NeutrinoAPI->GetServiceName(live_channel_id);//NeutrinoAPI->Zapit->getCurrentServiceID());
|
||||
NeutrinoAPI->GetStreamInfo(bitInfo);
|
||||
|
||||
|
||||
hh->ParamList["VideoFormat"] = string_printf("%d x %d", bitInfo[0], bitInfo[1] );
|
||||
hh->ParamList["BitRate"] = string_printf("%d\n", bitInfo[4]*50);
|
||||
|
||||
|
||||
switch ( bitInfo[2] ) //format
|
||||
{
|
||||
case 2: hh->ParamList["AspectRatio"] = "4:3"; break;
|
||||
@@ -733,7 +733,7 @@ std::string CNeutrinoYParser::func_get_current_stream_info(CyhookHandler *hh, s
|
||||
unsigned char mode = (header>> 6)&3;
|
||||
unsigned char copy = (header>> 3)&1;
|
||||
|
||||
hh->ParamList["AudioType"] =
|
||||
hh->ParamList["AudioType"] =
|
||||
string_printf("%s (%s/%s) %s", modenames[mode], sampfreqnames[sampfreq],
|
||||
layernames[layer], copy?"c":"");
|
||||
}
|
||||
@@ -743,7 +743,7 @@ std::string CNeutrinoYParser::func_get_current_stream_info(CyhookHandler *hh, s
|
||||
// Template 1:classname, 2:zAlarmTime, 3: zStopTime, 4:zRep, 5:zRepCouunt
|
||||
// 6:zType, 7:sAddData, 8:timer->eventID, 9:timer->eventID
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_get_timer_list(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_get_timer_list(CyhookHandler */*hh*/, std::string para)
|
||||
{
|
||||
std::string yresult;
|
||||
CTimerd::TimerList timerlist; // List of bouquets
|
||||
@@ -752,8 +752,8 @@ std::string CNeutrinoYParser::func_get_timer_list(CyhookHandler *hh, std::strin
|
||||
NeutrinoAPI->Timerd->getTimerList(timerlist);
|
||||
sort(timerlist.begin(), timerlist.end());
|
||||
|
||||
CZapitClient::BouquetChannelList channellist_tv;
|
||||
CZapitClient::BouquetChannelList channellist_radio;
|
||||
CZapitClient::BouquetChannelList channellist_tv;
|
||||
CZapitClient::BouquetChannelList channellist_radio;
|
||||
channellist_tv.clear();
|
||||
channellist_radio.clear();
|
||||
|
||||
@@ -777,7 +777,7 @@ std::string CNeutrinoYParser::func_get_timer_list(CyhookHandler *hh, std::strin
|
||||
if(timer->stopTime > 0)
|
||||
{
|
||||
struct tm *stopTime = localtime(&(timer->stopTime));
|
||||
strftime(zStopTime,20,"%d.%m. %H:%M",stopTime);
|
||||
strftime(zStopTime,20,"%d.%m. %H:%M",stopTime);
|
||||
}
|
||||
// repeat
|
||||
std::string zRep = NeutrinoAPI->timerEventRepeat2Str(timer->eventRepeat);
|
||||
@@ -885,10 +885,10 @@ std::string CNeutrinoYParser::func_set_timer_form(CyhookHandler *hh, std::strin
|
||||
// init timerid
|
||||
if(stimerid != "")
|
||||
timerId = (unsigned)atoi(stimerid.c_str());
|
||||
|
||||
|
||||
NeutrinoAPI->Timerd->getTimer(timer, timerId);
|
||||
std::string zType = NeutrinoAPI->timerEventType2Str(timer.eventType);
|
||||
|
||||
|
||||
hh->ParamList["timerId"] = itoa(timerId);
|
||||
hh->ParamList["zType"] = zType;
|
||||
}
|
||||
@@ -934,7 +934,7 @@ std::string CNeutrinoYParser::func_set_timer_form(CyhookHandler *hh, std::strin
|
||||
sel = (i==(int)timer.eventType) ? "selected=\"selected\"" : "";
|
||||
else
|
||||
sel = (i==(int)CTimerd::TIMER_RECORD) ? "selected=\"selected\"" : "";
|
||||
hh->ParamList["timertype"] +=
|
||||
hh->ParamList["timertype"] +=
|
||||
string_printf("<option value=\"%d\" %s>%s\n",i,sel.c_str(),zType.c_str());
|
||||
}
|
||||
}
|
||||
@@ -949,7 +949,7 @@ std::string CNeutrinoYParser::func_set_timer_form(CyhookHandler *hh, std::strin
|
||||
zRep = NeutrinoAPI->timerEventRepeat2Str((CTimerd::CTimerEventRepeat) i);
|
||||
if(cmd != "new")
|
||||
sel = (((int)timer.eventRepeat) == i) ? "selected=\"selected\"" : "";
|
||||
hh->ParamList["repeat"] +=
|
||||
hh->ParamList["repeat"] +=
|
||||
string_printf("<option value=\"%d\" %s>%s</option>\n",i,sel.c_str(),zRep.c_str());
|
||||
}
|
||||
}
|
||||
@@ -959,14 +959,14 @@ std::string CNeutrinoYParser::func_set_timer_form(CyhookHandler *hh, std::strin
|
||||
sel = "selected=\"selected\"";
|
||||
else
|
||||
sel = "";
|
||||
hh->ParamList["repeat"] +=
|
||||
hh->ParamList["repeat"] +=
|
||||
string_printf("<option value=\"%d\" %s>%s</option>\n",(int)CTimerd::TIMERREPEAT_WEEKDAYS, sel.c_str(), zRep.c_str());
|
||||
|
||||
// Weekdays
|
||||
char weekdays[8];
|
||||
NeutrinoAPI->Timerd->setWeekdaysToStr(timer.eventRepeat, weekdays);
|
||||
hh->ParamList["weekdays"]= weekdays;
|
||||
|
||||
|
||||
// timer repeats
|
||||
if (timer.eventRepeat == CTimerd::TIMERREPEAT_ONCE)
|
||||
hh->ParamList["TIMERREPEAT_ONCE"] = "y";
|
||||
@@ -993,7 +993,7 @@ std::string CNeutrinoYParser::func_set_timer_form(CyhookHandler *hh, std::strin
|
||||
}
|
||||
#if 0
|
||||
// program row
|
||||
CZapitClient::BouquetChannelList channellist;
|
||||
CZapitClient::BouquetChannelList channellist;
|
||||
channellist.clear();
|
||||
NeutrinoAPI->Zapit->getChannels(channellist,CZapitClient::MODE_TV, CZapitClient::SORT_BOUQUET, true);
|
||||
CZapitClient::BouquetChannelList::iterator channel = channellist.begin();
|
||||
@@ -1036,7 +1036,7 @@ std::string CNeutrinoYParser::func_set_timer_form(CyhookHandler *hh, std::strin
|
||||
hh->ParamList["standby"] = (cmd == "new")? "0" : ((timer.standby_on)?"1":"0");
|
||||
hh->ParamList["message"] = (cmd == "new")? "" : timer.message;
|
||||
hh->ParamList["pluginname"] = (cmd == "new")? "" : timer.pluginName;
|
||||
|
||||
|
||||
return "";
|
||||
}
|
||||
|
||||
@@ -1090,7 +1090,7 @@ std::string CNeutrinoYParser::func_bouquet_editor_main(CyhookHandler *hh, std::
|
||||
//-------------------------------------------------------------------------
|
||||
// func: Bouquet Edit
|
||||
//-------------------------------------------------------------------------
|
||||
std::string CNeutrinoYParser::func_set_bouquet_edit_form(CyhookHandler *hh, std::string para)
|
||||
std::string CNeutrinoYParser::func_set_bouquet_edit_form(CyhookHandler *hh, std::string /*para*/)
|
||||
{
|
||||
if (!(hh->ParamList["selected"].empty()))
|
||||
{
|
||||
|
Reference in New Issue
Block a user