diff --git a/lib/Makefile.am b/lib/Makefile.am index a0fc874fb..287c9d64f 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -1,7 +1,6 @@ SUBDIRS = \ connection \ libeventserver \ - controldclient \ sectionsdclient \ timerdclient \ libconfigfile \ diff --git a/src/Makefile.am b/src/Makefile.am index ad613693e..5be97e84d 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -42,7 +42,6 @@ neutrino_LDADD = \ nhttpd/tuxboxapi/libnhttpd_tuxboxapi.a \ nhttpd/yhttpd_mods/libyhttpdmods.a \ nhttpd/yhttpd_core/libyhttpd.a \ - $(top_builddir)/lib/controldclient/libcontroldclient.la \ $(top_builddir)/lib/sectionsdclient/libsectionsdclient.a \ $(top_builddir)/lib/timerdclient/libtimerdclient.a \ $(top_builddir)/src/zapit/lib/libzapitclient.a \ diff --git a/src/driver/rcinput.cpp b/src/driver/rcinput.cpp index 82ac7cce8..470455bd0 100644 --- a/src/driver/rcinput.cpp +++ b/src/driver/rcinput.cpp @@ -741,6 +741,7 @@ void CRCInput::getMsg_us(neutrino_msg_t * msg, neutrino_msg_data_t * data, uint6 read_bytes= recv(fd_eventclient, p, emsg.dataSize, MSG_WAITALL); //printf("[neutrino] eventbody read %d bytes - initiator %x\n", read_bytes, emsg.initiatorID ); +#if 0 if ( emsg.initiatorID == CEventServer::INITID_CONTROLD ) { switch(emsg.eventID) @@ -766,7 +767,9 @@ void CRCInput::getMsg_us(neutrino_msg_t * msg, neutrino_msg_data_t * data, uint6 printf("[neutrino] event INITID_CONTROLD - unknown eventID 0x%x\n", emsg.eventID ); } } - else if ( emsg.initiatorID == CEventServer::INITID_HTTPD ) + else +#endif + if ( emsg.initiatorID == CEventServer::INITID_HTTPD ) { switch(emsg.eventID) { diff --git a/src/gui/audioplayer.cpp b/src/gui/audioplayer.cpp index 8a337ab3c..4d4ee9570 100644 --- a/src/gui/audioplayer.cpp +++ b/src/gui/audioplayer.cpp @@ -263,13 +263,11 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &) m_current = 0; m_selected = 0; - //m_width = 710; - //if((g_settings.screen_EndX - g_settings.screen_StartX) < m_width+ConnectLineBox_Width) m_width=(g_settings.screen_EndX - g_settings.screen_StartX) - ConnectLineBox_Width - 5; - //m_height = 570; - //if((g_settings.screen_EndY - g_settings.screen_StartY) < m_height) + m_height = (g_settings.screen_EndY - g_settings.screen_StartY - 5); m_sheight = g_Font[SNeutrinoSettings::FONT_TYPE_INFOBAR_SMALL]->getHeight(); + m_buttonHeight = std::min(25, m_sheight); m_theight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU_TITLE]->getHeight(); m_fheight = g_Font[SNeutrinoSettings::FONT_TYPE_MENU]->getHeight(); @@ -288,15 +286,11 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &) { parent->hide(); } -#if 0 - if (g_settings.video_Format != g_settings.video_backgroundFormat) - g_Controld->setVideoFormat(g_settings.video_backgroundFormat); -#endif + bool usedBackground = m_frameBuffer->getuseBackground(); if (usedBackground) m_frameBuffer->saveBackgroundImage(); - // set zapit in standby mode g_Zapit->stopPlayBack(); @@ -304,18 +298,9 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &) // tell neutrino we're in audio mode CNeutrinoApp::getInstance()->handleMsg( NeutrinoMessages::CHANGEMODE , NeutrinoMessages::mode_audio ); -#if 0 - // remember last mode - CZapitClient::responseGetLastChannel firstchannel; - g_Zapit->getLastChannel(firstchannel.channelNumber, firstchannel.mode); - if ((firstchannel.mode == 'r') ? - (CNeutrinoApp::getInstance()->zapto_radio_on_init_done) : - (CNeutrinoApp::getInstance()->zapto_tv_on_init_done)) - m_LastMode=(CNeutrinoApp::getInstance()->getLastMode() | NeutrinoMessages::norezap); - else - m_LastMode=(CNeutrinoApp::getInstance()->getLastMode()); -#endif + m_LastMode=(CNeutrinoApp::getInstance()->getLastMode()); + // Stop sectionsd g_Sectionsd->setPauseScanning(true); @@ -331,11 +316,6 @@ int CAudioPlayerGui::exec(CMenuTarget* parent, const std::string &) m_frameBuffer->useBackground(usedBackground); m_frameBuffer->paintBackground(); - // Restore last mode - //t_channel_id channel_id=CNeutrinoApp::getInstance()->channelList->getActiveChannel_ChannelID(); - //g_Zapit->zapTo_serviceID(channel_id); - //g_Zapit->setStandby(false); - puts("[audioplayer.cpp] executing " AUDIOPLAYER_END_SCRIPT "."); if (system(AUDIOPLAYER_END_SCRIPT) != 0) perror("Datei " AUDIOPLAYER_END_SCRIPT " fehlt. Bitte erstellen, wenn gebraucht.\nFile " AUDIOPLAYER_END_SCRIPT " not found. Please create if needed.\n"); diff --git a/src/gui/movieplayer.cpp b/src/gui/movieplayer.cpp index 42ccd9947..583bba8ca 100644 --- a/src/gui/movieplayer.cpp +++ b/src/gui/movieplayer.cpp @@ -133,8 +133,6 @@ std::string g_file_epg; std::string g_file_epg1; bool showaudioselectdialog = false; -void checkAspectRatio(int vdec, bool init); - bool get_movie_info_apid_name(int apid, MI_MOVIE_INFO * movie_info, std::string * apidtitle) { if (movie_info == NULL || apidtitle == NULL) @@ -1262,41 +1260,6 @@ void CMoviePlayerGui::PlayFile(void) InfoClock->StartClock(); } -// checks if AR has changed an sets cropping mode accordingly (only video mode auto) -static short archeck; -void checkAspectRatio(int /*vdec*/, bool init) -{ - static time_t last_check = 0; - - // only necessary for auto mode, check each 5 sec. max - if (g_settings.video_Format != 0 || (!init && time(NULL) <= last_check + archeck)) - return; -#if 0 - char aspectRatio = 2; - if (init) { - aspectRatio = g_Controld->getAspectRatio(); - last_check = 0; - archeck = 1; - return; - } else { - char newRatio = g_Controld->getAspectRatio(); - if (newRatio != aspectRatio) { - printf("[movieplayer] AR change detected in auto mode, adjusting display format\n"); - video_displayformat_t vdt; - if (newRatio == 2) - vdt = VIDEO_LETTER_BOX; - else - vdt = VIDEO_CENTER_CUT_OUT; - if (ioctl(vdec, VIDEO_SET_DISPLAY_FORMAT, vdt)) - perror("[movieplayer] VIDEO_SET_DISPLAY_FORMAT"); - aspectRatio = newRatio; - archeck = 5; - } - last_check = time(NULL); - } -#endif -} - void CMoviePlayerGui::showHelpTS() { Helpbox helpbox; diff --git a/src/gui/plugins.cpp b/src/gui/plugins.cpp index f55329a79..374b7f152 100644 --- a/src/gui/plugins.cpp +++ b/src/gui/plugins.cpp @@ -466,9 +466,6 @@ void CPlugins::startPlugin(int number,int /*param*/) if (ispip) { g_Sectionsd->setPauseScanning (true); g_Zapit->setEventMode(false); -#if 0 - //g_Controld->setEventMode(false); -#endif if (g_Zapit->isPlayBackActive()) { if (!CNeutrinoApp::getInstance()->recordingstatus) g_Zapit->setRecordMode(true); @@ -520,9 +517,6 @@ void CPlugins::startPlugin(int number,int /*param*/) if (!CNeutrinoApp::getInstance()->recordingstatus) { g_Zapit->setRecordMode(false); } -#if 0 - //g_Controld->setEventMode(true); -#endif g_Zapit->setEventMode(true); g_Sectionsd->setPauseScanning (false); } diff --git a/src/gui/upnpbrowser.cpp b/src/gui/upnpbrowser.cpp index cd6e2fefd..dcbf1bc91 100644 --- a/src/gui/upnpbrowser.cpp +++ b/src/gui/upnpbrowser.cpp @@ -804,12 +804,6 @@ bool CUpnpBrowserGui::selectItem(std::string id) if (g_settings.video_Format==1) viewer->SetAspectRatio(16.0/9); - else if (g_settings.video_Format==0) - { - CControldClient cdc; - cdc.setVideoFormat(CControldClient::VIDEOFORMAT_4_3); - viewer->SetAspectRatio(4.0/3); - } else viewer->SetAspectRatio(4.0/3); diff --git a/src/gui/widget/Makefile.am b/src/gui/widget/Makefile.am index e7bba9153..0b9e4c744 100644 --- a/src/gui/widget/Makefile.am +++ b/src/gui/widget/Makefile.am @@ -16,7 +16,6 @@ libneutrino_gui_widget_a_SOURCES = \ colorchooser.cpp keychooser.cpp \ menue.cpp stringinput.cpp stringinput_ext.cpp \ messagebox.cpp hintbox.cpp listbox.cpp listbox_legacy.cpp \ - rgbcsynccontroler.cpp \ drawable.cpp hintboxext.cpp helpbox.cpp mountchooser.cpp \ listframe.cpp msgbox.cpp textbox.cpp progressbar.cpp diff --git a/src/neutrino.cpp b/src/neutrino.cpp index 60567a202..f7e5709f9 100644 --- a/src/neutrino.cpp +++ b/src/neutrino.cpp @@ -299,9 +299,7 @@ static void initGlobals(void) g_fontRenderer = NULL; g_RCInput = NULL; - //g_Controld = new CControldClient; g_Timerd = NULL; - //g_Zapit = new CZapitClient; g_RemoteControl = NULL; g_EpgData = NULL; @@ -2445,12 +2443,6 @@ int CNeutrinoApp::run(int argc, char **argv) InitScanSettings(_scanSettings); dprintf( DEBUG_NORMAL, "registering as event client\n"); -#if 0 - g_Controld->registerEvent(CControldClient::EVT_MUTECHANGED, 222, NEUTRINO_UDS_NAME); - g_Controld->registerEvent(CControldClient::EVT_VOLUMECHANGED, 222, NEUTRINO_UDS_NAME); - g_Controld->registerEvent(CControldClient::EVT_MODECHANGED, 222, NEUTRINO_UDS_NAME); - g_Controld->registerEvent(CControldClient::EVT_VCRCHANGED, 222, NEUTRINO_UDS_NAME); -#endif g_Sectionsd->registerEvent(CSectionsdClient::EVT_TIMESET, 222, NEUTRINO_UDS_NAME); g_Sectionsd->registerEvent(CSectionsdClient::EVT_GOT_CN_EPG, 222, NEUTRINO_UDS_NAME); @@ -3148,9 +3140,11 @@ _repeat: return messages_return::handled | messages_return::cancel_info; } else if( msg == NeutrinoMessages::EVT_MUTECHANGED ) { +#if 0 CControldMsg::commandMute* cmd = (CControldMsg::commandMute*) data; if(cmd->type == (CControld::volume_type)g_settings.audio_avs_Control) AudioMute( cmd->mute, true ); +#endif delete[] (unsigned char*) data; return messages_return::handled; } @@ -3728,13 +3722,11 @@ void CNeutrinoApp::setVolume(const neutrino_msg_t key, const bool bDoPaint, bool } setvol(g_settings.current_volume,(g_settings.audio_avs_Control)); - //timeoutEnd = CRCInput::calcTimeoutEnd(nowait ? 1 : g_settings.timing[SNeutrinoSettings::TIMING_INFOBAR] / 2); timeoutEnd = CRCInput::calcTimeoutEnd(nowait ? 1 : 3); } else if (msg == NeutrinoMessages::EVT_VOLCHANGED) { //current_volume = g_Controld->getVolume((CControld::volume_type)g_settings.audio_avs_Control);//FIXME //printf("setVolume EVT_VOLCHANGED %d\n", current_volume); - //timeoutEnd = CRCInput::calcTimeoutEnd(g_settings.timing[SNeutrinoSettings::TIMING_INFOBAR] / 2); timeoutEnd = CRCInput::calcTimeoutEnd(3); } else if (handleMsg(msg, data) & messages_return::unhandled) { diff --git a/src/neutrino_menue.cpp b/src/neutrino_menue.cpp index 0a84c6932..bc56e22b4 100644 --- a/src/neutrino_menue.cpp +++ b/src/neutrino_menue.cpp @@ -266,7 +266,7 @@ const CMenuOptionChooser::keyval VIDEOMENU_DBDR_OPTIONS[VIDEOMENU_DBDR_OPTION_CO }; #include "videosettings.h" -CVideoSettings::CVideoSettings() : CMenuWidget(LOCALE_VIDEOMENU_HEAD, NEUTRINO_ICON_VIDEO), RGBCSyncControler(LOCALE_VIDEOMENU_RGB_CENTERING, &g_settings.video_csync) +CVideoSettings::CVideoSettings() : CMenuWidget(LOCALE_VIDEOMENU_HEAD, NEUTRINO_ICON_VIDEO) /*, RGBCSyncControler(LOCALE_VIDEOMENU_RGB_CENTERING, &g_settings.video_csync)*/ { addItem(GenericMenuSeparator); addItem(GenericMenuBack); @@ -1608,14 +1608,6 @@ const CMenuOptionChooser::keyval AUDIOMENU_ANALOGOUT_OPTIONS[AUDIOMENU_ANALOGOUT { 2, LOCALE_AUDIOMENU_MONORIGHT } }; -#define AUDIOMENU_AVS_CONTROL_OPTION_COUNT 3 -const CMenuOptionChooser::keyval AUDIOMENU_AVS_CONTROL_OPTIONS[AUDIOMENU_AVS_CONTROL_OPTION_COUNT] = -{ - { CControld::TYPE_OST , LOCALE_AUDIOMENU_OST }, - { CControld::TYPE_AVS , LOCALE_AUDIOMENU_AVS }, - { CControld::TYPE_LIRC, LOCALE_AUDIOMENU_LIRC } -}; - #define AUDIOMENU_SRS_OPTION_COUNT 2 const CMenuOptionChooser::keyval AUDIOMENU_SRS_OPTIONS[AUDIOMENU_SRS_OPTION_COUNT] = { @@ -1659,7 +1651,7 @@ void CNeutrinoApp::InitAudioSettings(CMenuWidget &audioSettings, CAudioSetupNoti #if 0 CStringInput * audio_PCMOffset = new CStringInput(LOCALE_AUDIOMENU_PCMOFFSET, g_settings.audio_PCMOffset, 2, NONEXISTANT_LOCALE, NONEXISTANT_LOCALE, "0123456789 ", audioSetupNotifier); - CMenuForwarder *mf = new CMenuForwarder(LOCALE_AUDIOMENU_PCMOFFSET, (g_settings.audio_avs_Control == CControld::TYPE_LIRC), g_settings.audio_PCMOffset, audio_PCMOffset ); + CMenuForwarder *mf = new CMenuForwarder(LOCALE_AUDIOMENU_PCMOFFSET, true, g_settings.audio_PCMOffset, audio_PCMOffset ); audioSettings.addItem(mf); #endif } diff --git a/src/nhttpd/tuxboxapi/controlapi.cpp b/src/nhttpd/tuxboxapi/controlapi.cpp index 752b79015..78937864e 100644 --- a/src/nhttpd/tuxboxapi/controlapi.cpp +++ b/src/nhttpd/tuxboxapi/controlapi.cpp @@ -760,12 +760,15 @@ void CControlAPI::RCEmCGI(CyhookHandler *hh) //----------------------------------------------------------------------------- void CControlAPI::AspectRatioCGI(CyhookHandler *hh) { +#if HAVE_DBOX2 // FIXME: not implemented hh->printf("%s", NeutrinoAPI->Controld->getAspectRatio() == '\0' ? "4:3" : "16:9"); +#endif } //----------------------------------------------------------------------------- void CControlAPI::VideoFormatCGI(CyhookHandler *hh) { +#if HAVE_DBOX2 // FIXME: not implemented if (hh->ParamList.empty() || hh->ParamList["1"] == "status") { hh->WriteLn(NeutrinoAPI->videoformat_names[(unsigned int)NeutrinoAPI->Controld->getVideoFormat()]); return; @@ -788,11 +791,14 @@ void CControlAPI::VideoFormatCGI(CyhookHandler *hh) } else { hh->SendError(); } +#endif + hh->SendOk(); } //----------------------------------------------------------------------------- void CControlAPI::VideoOutputCGI(CyhookHandler *hh) { +#if HAVE_DBOX2 // FIXME: not implemented unsigned int videooutput=0; if (hh->ParamList.empty() || hh->ParamList["1"] == "status") { hh->WriteLn(NeutrinoAPI->videooutput_names[(unsigned int) NeutrinoAPI->Controld->getVideoOutput()]); @@ -812,12 +818,14 @@ void CControlAPI::VideoOutputCGI(CyhookHandler *hh) } NeutrinoAPI->Controld->setVideoOutput(videooutput); +#endif hh->SendOk(); } //----------------------------------------------------------------------------- void CControlAPI::VCROutputCGI(CyhookHandler *hh) { +#if HAVE_DBOX2 // FIXME: not implemented unsigned int vcroutput; if (hh->ParamList.empty() || hh->ParamList["1"] == "status") { hh->WriteLn(NeutrinoAPI->videooutput_names[(unsigned char)NeutrinoAPI->Controld->getVCROutput()]); @@ -840,6 +848,7 @@ void CControlAPI::VCROutputCGI(CyhookHandler *hh) return; } NeutrinoAPI->Controld->setVCROutput(vcroutput); +#endif hh->SendOk(); return; @@ -848,6 +857,7 @@ void CControlAPI::VCROutputCGI(CyhookHandler *hh) //----------------------------------------------------------------------------- void CControlAPI::ScartModeCGI(CyhookHandler *hh) { +#if HAVE_DBOX2 // FIXME: not implemented bool new_status; if (hh->ParamList.empty() || hh->ParamList["1"] == "status") { hh->printf(NeutrinoAPI->Controld->getScartMode() ? "on" : "off"); @@ -861,14 +871,20 @@ void CControlAPI::ScartModeCGI(CyhookHandler *hh) return; } NeutrinoAPI->Controld->setScartMode(new_status); +#endif hh->SendOk(); } //------------------------------------------------------------------------- void CControlAPI::VolumeCGI(CyhookHandler *hh) { - if (hh->ParamList.empty()) //without param: show actual volumen - hh->printf("%d", NeutrinoAPI->Controld->getVolume()); + if (hh->ParamList.empty()) { //without param: show actual volumen + unsigned int volume; + NeutrinoAPI->Zapit->getVolume(&volume, &volume); + hh->printf("%d", volume); + //hh->printf("%d", NeutrinoAPI->Controld->getVolume()); + } + else if (hh->ParamList["1"].compare("mute") == 0) { NeutrinoAPI->Zapit->muteAudio(true); @@ -883,7 +899,8 @@ void CControlAPI::VolumeCGI(CyhookHandler *hh) { hh->Write((char *) (NeutrinoAPI->Controld->getMute() ? "1" : "0")); // mute - }*/ + } +*/ else if(hh->ParamList["1"]!="") { //set volume char vol = atol( hh->ParamList["1"].c_str() ); @@ -1546,6 +1563,7 @@ void CControlAPI::SendAllCurrentVAPid(CyhookHandler *hh) //----------------------------------------------------------------------------- void CControlAPI::SendSettings(CyhookHandler *hh) { +#if 0 hh->WriteLn( "Boxtype " + NeutrinoAPI->Dbox_Hersteller[NeutrinoAPI->Controld->getBoxType()] + @@ -1556,6 +1574,7 @@ void CControlAPI::SendSettings(CyhookHandler *hh) "videoformat " + NeutrinoAPI->videoformat_names[(unsigned char)NeutrinoAPI->Controld->getVideoFormat()] ); +#endif } //----------------------------------------------------------------------------- diff --git a/src/nhttpd/tuxboxapi/neutrinoapi.cpp b/src/nhttpd/tuxboxapi/neutrinoapi.cpp index 01da03bbc..c544559da 100644 --- a/src/nhttpd/tuxboxapi/neutrinoapi.cpp +++ b/src/nhttpd/tuxboxapi/neutrinoapi.cpp @@ -85,7 +85,7 @@ std::string CNeutrinoAPI::audiotype_names[5] = {"none", "single channel","dual //============================================================================= CNeutrinoAPI::CNeutrinoAPI() { - Controld = new CControldClient(); + //Controld = new CControldClient(); Sectionsd = new CSectionsdClient(); Zapit = new CZapitClient(); Timerd = new CTimerdClient(); @@ -118,8 +118,8 @@ CNeutrinoAPI::~CNeutrinoAPI(void) delete NeutrinoYParser; if (ControlAPI) delete ControlAPI; - if (Controld) - delete Controld; + //if (Controld) + // delete Controld; if (Sectionsd) delete Sectionsd; if (Zapit) diff --git a/src/nhttpd/tuxboxapi/neutrinoapi.h b/src/nhttpd/tuxboxapi/neutrinoapi.h index a1a076a4b..38c36d0b1 100644 --- a/src/nhttpd/tuxboxapi/neutrinoapi.h +++ b/src/nhttpd/tuxboxapi/neutrinoapi.h @@ -6,7 +6,7 @@ #include // tuxbox -#include +//#include #include #include #include @@ -28,7 +28,7 @@ bool _initialize_iso639_map(void); class CNeutrinoAPI { // Clientlibs - CControldClient *Controld; + //CControldClient *Controld; CSectionsdClient *Sectionsd; CZapitClient *Zapit; CTimerdClient *Timerd; diff --git a/src/nhttpd/tuxboxapi/neutrinoyparser.cpp b/src/nhttpd/tuxboxapi/neutrinoyparser.cpp index d394342e9..c73db32a3 100644 --- a/src/nhttpd/tuxboxapi/neutrinoyparser.cpp +++ b/src/nhttpd/tuxboxapi/neutrinoyparser.cpp @@ -680,9 +680,10 @@ std::string CNeutrinoYParser::func_get_partition_list(CyhookHandler */*hh*/, st //------------------------------------------------------------------------- // 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()]; + return "Coolstream";//FIXME + //return NeutrinoAPI->Dbox_Hersteller[NeutrinoAPI->Controld->getBoxType()]; } //------------------------------------------------------------------------- // y-func : get stream info diff --git a/src/videosettings.h b/src/videosettings.h index 6bdda40b2..ba2252431 100644 --- a/src/videosettings.h +++ b/src/videosettings.h @@ -5,7 +5,7 @@ class CVideoSettings : public CMenuWidget, CChangeObserver { CMenuForwarder * SyncControlerForwarder; CMenuOptionChooser * VcrVideoOutSignalOptionChooser; - CRGBCSyncControler RGBCSyncControler; + /*CRGBCSyncControler RGBCSyncControler;*/ int vcr_video_out_signal; public: