From a9882cdc22b68412bd8e617a72ff1fe4b41c90a9 Mon Sep 17 00:00:00 2001 From: svenhoefer Date: Thu, 3 Sep 2020 22:07:12 +0200 Subject: [PATCH] - rename BOXMODEL_CS => BOXMODEL_CST Conflicts: data/scripts/Makefile.am src/gui/cam_menu.cpp src/gui/imageinfo_ni.cpp src/gui/osd_setup.cpp src/gui/update.cpp src/gui/update.h src/gui/update_menue.cpp src/neutrino.cpp src/system/setting_helpers.cpp Signed-off-by: Thilo Graf --- acinclude.m4 | 8 ++++---- data/fonts/Makefile.am | 2 +- data/scripts/Makefile.am | 2 +- src/Makefile.am | 6 +++--- src/driver/Makefile.am | 2 +- src/driver/fade.cpp | 6 +++--- src/driver/fb_generic.cpp | 6 +++--- src/driver/rcinput.cpp | 2 +- src/driver/rcinput.h | 2 +- src/driver/screenshot.cpp | 14 +++++++------- src/driver/screenshot.h | 2 +- src/driver/vfd.cpp | 8 ++++---- src/driver/vfd.h | 2 +- src/drivertool.c | 2 +- src/eitd/edvbstring.cpp | 8 ++++---- src/gui/audio_setup.cpp | 8 ++++---- src/gui/cam_menu.cpp | 4 ++-- src/gui/movieplayer.cpp | 2 +- src/gui/osd_helpers.cpp | 2 +- src/gui/osd_setup.cpp | 14 ++++++++++++++ src/gui/streaminfo1.cpp | 2 +- src/gui/update.cpp | 32 ++++++++++++++++---------------- src/gui/update.h | 11 ++++++----- src/gui/update_ext.cpp | 2 +- src/gui/update_menue.cpp | 5 ++++- src/gui/update_settings.cpp | 4 ++-- src/gui/videosettings.cpp | 26 +++++++++++++------------- src/neutrino.cpp | 10 +++++++--- src/system/Makefile.am | 2 +- src/system/flashtool.cpp | 4 ++-- src/system/setting_helpers.cpp | 7 ++++--- src/system/settings.h | 2 +- src/zapit/src/capmt.cpp | 6 +++--- src/zapit/src/zapit.cpp | 4 ++-- 34 files changed, 121 insertions(+), 98 deletions(-) diff --git a/acinclude.m4 b/acinclude.m4 index 70ef4ce22..58b973c3e 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -532,8 +532,8 @@ AM_CONDITIONAL(BOXMODEL_GENERIC, test "$BOXMODEL" = "generic") AM_CONDITIONAL(BOXMODEL_RASPI, test "$BOXMODEL" = "raspi") # coolstream -AM_CONDITIONAL(BOXMODEL_CS_HD1, test "$BOXMODEL" = "hd1") -AM_CONDITIONAL(BOXMODEL_CS_HD2, test "$BOXMODEL" = "hd2") +AM_CONDITIONAL(BOXMODEL_CST_HD1, test "$BOXMODEL" = "hd1") +AM_CONDITIONAL(BOXMODEL_CST_HD2, test "$BOXMODEL" = "hd2") # armbox AM_CONDITIONAL(BOXMODEL_HD51, test "$BOXMODEL" = "hd51") @@ -586,9 +586,9 @@ if test "$BOXMODEL" = "generic"; then elif test "$BOXMODEL" = "raspi"; then AC_DEFINE(BOXMODEL_RASPI, 1, [raspberry pi]) elif test "$BOXMODEL" = "hd1"; then - AC_DEFINE(BOXMODEL_CS_HD1, 1, [coolstream hd1/neo/neo2/zee]) + AC_DEFINE(BOXMODEL_CST_HD1, 1, [coolstream hd1/neo/neo2/zee]) elif test "$BOXMODEL" = "hd2"; then - AC_DEFINE(BOXMODEL_CS_HD2, 1, [coolstream tank/trinity/trinity v2/trinity duo/zee2/link]) + AC_DEFINE(BOXMODEL_CST_HD2, 1, [coolstream tank/trinity/trinity v2/trinity duo/zee2/link]) elif test "$BOXMODEL" = "hd51"; then AC_DEFINE(BOXMODEL_HD51, 1, [hd51]) elif test "$BOXMODEL" = "hd60"; then diff --git a/data/fonts/Makefile.am b/data/fonts/Makefile.am index 0c183df60..0a832e495 100644 --- a/data/fonts/Makefile.am +++ b/data/fonts/Makefile.am @@ -17,7 +17,7 @@ install_DATA = \ tuxtxt.otb -if BOXMODEL_CS_HD2 +if BOXMODEL_CST_HD2 install_DATA += UnDotum.ttf endif diff --git a/data/scripts/Makefile.am b/data/scripts/Makefile.am index 370d66c5b..fc94aed56 100644 --- a/data/scripts/Makefile.am +++ b/data/scripts/Makefile.am @@ -5,7 +5,7 @@ install_SCRIPTS = \ restore.sh \ install.sh -# if BOXMODEL_CS_HD2 +# if BOXMODEL_CST_HD2 # install_SCRIPTS += \ # backup_flash.sh \ # restore_flash.sh diff --git a/src/Makefile.am b/src/Makefile.am index 5064ca4b4..77a517601 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -63,7 +63,7 @@ endif AM_CPPFLAGS += -D_FILE_OFFSET_BITS=64 -if BOXMODEL_CS_HD2 +if BOXMODEL_CST_HD2 MTDUTILSLIBS = \ system/mtdutils/libneutrino_system_mtdutils.a \ system/mtdutils/lib/libneutrino_system_mtdutils_lib.a @@ -166,13 +166,13 @@ else neutrino_LDADD += -lcoolstream-mt -lca-sc endif -if BOXMODEL_CS_HD2 +if BOXMODEL_CST_HD2 neutrino_LDADD += -lca-ci -llnxtmvssUsr -llnxUKAL -llnxplatUsr -llnxtmasUsr -llnxdvbciUsr -llnxpvrUsr -llnxcssUsr -llnxnotifyqUsr -ltmpvrDataManager-cst -ltmpvrIndexStorage -llnxscsUsr else neutrino_LDADD += -lnxp endif -if BOXMODEL_CS_HD2 +if BOXMODEL_CST_HD2 neutrino_LDADD += -liconv endif diff --git a/src/driver/Makefile.am b/src/driver/Makefile.am index 6a850691d..1237658d5 100644 --- a/src/driver/Makefile.am +++ b/src/driver/Makefile.am @@ -59,7 +59,7 @@ endif if BOXTYPE_COOL libneutrino_driver_a_SOURCES += \ fb_accel_cs_hdx.cpp -if BOXMODEL_CS_HD2 +if BOXMODEL_CST_HD2 libneutrino_driver_a_SOURCES += \ fb_accel_cs_hd2.cpp \ vfd.cpp diff --git a/src/driver/fade.cpp b/src/driver/fade.cpp index a23f84bfc..4c993e9b5 100644 --- a/src/driver/fade.cpp +++ b/src/driver/fade.cpp @@ -58,7 +58,7 @@ void COSDFader::StartFadeIn() frameBuffer->setBlendMode(2); // Global alpha multiplied with pixel alpha frameBuffer->setBlendLevel(fadeValue); -#if HAVE_SPARK_HARDWARE || (HAVE_CST_HARDWARE && defined(BOXMODEL_CS_HD2)) +#if HAVE_SPARK_HARDWARE || (HAVE_CST_HARDWARE && defined(BOXMODEL_CST_HD2)) usleep(60000); #endif fadeTimer = g_RCInput->addTimer( FADE_TIME, false ); @@ -86,7 +86,7 @@ void COSDFader::StopFade() if ( fadeIn || fadeOut ) { g_RCInput->killTimer(fadeTimer); frameBuffer->setBlendMode(1); // Global alpha multiplied with pixel alpha -#if HAVE_SPARK_HARDWARE || (HAVE_CST_HARDWARE && defined(BOXMODEL_CS_HD2)) +#if HAVE_SPARK_HARDWARE || (HAVE_CST_HARDWARE && defined(BOXMODEL_CST_HD2)) usleep(60000); #endif fadeIn = fadeOut = false; @@ -113,7 +113,7 @@ bool COSDFader::FadeDone() g_RCInput->killTimer (fadeTimer); fadeIn = false; frameBuffer->setBlendMode(1); // Global alpha multiplied with pixel alpha -#if HAVE_SPARK_HARDWARE || (HAVE_CST_HARDWARE && defined(BOXMODEL_CS_HD2)) +#if HAVE_SPARK_HARDWARE || (HAVE_CST_HARDWARE && defined(BOXMODEL_CST_HD2)) usleep(60000); #endif } else diff --git a/src/driver/fb_generic.cpp b/src/driver/fb_generic.cpp index 67399ac63..d2ead9bef 100644 --- a/src/driver/fb_generic.cpp +++ b/src/driver/fb_generic.cpp @@ -130,10 +130,10 @@ CFrameBuffer* CFrameBuffer::getInstance() frameBuffer = new CFbAccelSTi(); #endif #if HAVE_CST_HARDWARE -#ifdef BOXMODEL_CS_HD1 +#ifdef BOXMODEL_CST_HD1 frameBuffer = new CFbAccelCSHD1(); #endif -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 frameBuffer = new CFbAccelCSHD2(); #endif #endif @@ -542,7 +542,7 @@ fb_pixel_t* CFrameBuffer::paintBoxRel(const int x, const int y, const int dx, co int w_align; int offs_align; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (_dx%4 != 0) { w_align = getWidth4FB_HW_ACC(x, _dx, true); if (w_align < _dx) diff --git a/src/driver/rcinput.cpp b/src/driver/rcinput.cpp index f1ab69733..7f6e52d4c 100644 --- a/src/driver/rcinput.cpp +++ b/src/driver/rcinput.cpp @@ -1796,7 +1796,7 @@ void CRCInput::setKeyRepeatDelay(unsigned int start_ms, unsigned int repeat_ms) std::string path = (*it).path; if (path == "/tmp/neutrino.input") continue; /* setting repeat rate does not work here */ -#ifdef BOXMODEL_CS_HD1 +#ifdef BOXMODEL_CST_HD1 /* this is ugly, but the driver does not support anything advanced... */ if (path == "/dev/input/nevis_ir") { d_printf("[rcinput:%s] %s(fd %d) using proprietary ioctl\n", __func__, path.c_str(), fd); diff --git a/src/driver/rcinput.h b/src/driver/rcinput.h index e43f27a07..dd7d498b2 100644 --- a/src/driver/rcinput.h +++ b/src/driver/rcinput.h @@ -42,7 +42,7 @@ #include #include -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 #ifdef HAVE_COOLSTREAM_CS_IR_GENERIC_H #include #endif diff --git a/src/driver/screenshot.cpp b/src/driver/screenshot.cpp index 544c5761d..5d0c0aca1 100644 --- a/src/driver/screenshot.cpp +++ b/src/driver/screenshot.cpp @@ -135,7 +135,7 @@ bool CScreenShot::StartSync() } #else // SCREENSHOT_INTERNAL -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 bool CScreenShot::mergeOsdScreen(uint32_t dx, uint32_t dy, fb_pixel_t* osdData) { @@ -174,7 +174,7 @@ bool CScreenShot::mergeOsdScreen(uint32_t dx, uint32_t dy, fb_pixel_t* osdData) /* try to get video frame data in ARGB format, restore GXA state */ bool CScreenShot::GetData() { -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 /* Workaround for broken osd screenshot with new fb driver and 1280x720 resolution */ CFrameBuffer* frameBuffer = CFrameBuffer::getInstance(); fb_pixel_t* screenBuf = NULL; @@ -198,12 +198,12 @@ bool CScreenShot::GetData() bool res = false; pthread_mutex_lock(&getData_mutex); -#ifdef BOXMODEL_CS_HD1 +#ifdef BOXMODEL_CST_HD1 CFrameBuffer::getInstance()->setActive(false); #endif if (videoDecoder->getBlank()) get_video = false; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (extra_osd && !get_video) { uint32_t memSize = xres * yres * sizeof(fb_pixel_t) * 2; pixel_data = (uint8_t*)cs_malloc_uncached(memSize); @@ -221,7 +221,7 @@ bool CScreenShot::GetData() res = videoDecoder->GetScreenImage(pixel_data, xres, yres, get_video, get_osd, scale_to_video); #endif -#ifdef BOXMODEL_CS_HD1 +#ifdef BOXMODEL_CST_HD1 /* sort of hack. GXA used to transfer/convert live image to RGB, * so setup GXA back */ CFrameBuffer::getInstance()->setupGXA(); @@ -234,7 +234,7 @@ bool CScreenShot::GetData() return false; } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (extra_osd && screenBuf) { printf("[CScreenShot::%s:%d] Merge osd screen to screenshot...", __func__, __LINE__); mergeOsdScreen(_xres, _yres, screenBuf); @@ -395,7 +395,7 @@ bool CScreenShot::SavePng() png_set_compression_level(png_ptr, Z_BEST_SPEED); png_set_bgr(png_ptr); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 png_set_invert_alpha(png_ptr); #endif png_write_info(png_ptr, info_ptr); diff --git a/src/driver/screenshot.h b/src/driver/screenshot.h index 2e9d77c5d..3ba6967b6 100644 --- a/src/driver/screenshot.h +++ b/src/driver/screenshot.h @@ -72,7 +72,7 @@ class CScreenShot void runThread(); static void cleanupThread(void *arg); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 bool mergeOsdScreen(uint32_t dx, uint32_t dy, fb_pixel_t* osdData); #endif #endif // SCREENSHOT_INTERNAL diff --git a/src/driver/vfd.cpp b/src/driver/vfd.cpp index 8f3c930d4..6e72e73e4 100644 --- a/src/driver/vfd.cpp +++ b/src/driver/vfd.cpp @@ -70,7 +70,7 @@ CVFD::CVFD() has_led_segment = false; } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (fd >= 0) { int ret = ioctl(fd, IOC_FP_GET_DISPLAY_CAPS, &caps); if (ret < 0) { @@ -370,7 +370,7 @@ void CVFD::showTime(bool force) ShowText(timestr); } else if (support_numbers && has_led_segment) { ShowNumber((t.tm_hour*100) + t.tm_min); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 ioctl(fd, IOC_FP_SET_COLON, 0x01); #endif } @@ -568,7 +568,7 @@ void CVFD::setMode(const MODES m, const char * const title) if(fd < 0) return; // Clear colon in display if it is still there -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (support_numbers && has_led_segment) ioctl(fd, IOC_FP_SET_COLON, 0x00); #endif @@ -823,7 +823,7 @@ void CVFD::ShowNumber(int number) if (number < 0) return; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 int ret = ioctl(fd, IOC_FP_SET_NUMBER, number); if(ret < 0) { support_numbers = false; diff --git a/src/driver/vfd.h b/src/driver/vfd.h index 6a6859cb0..5f5d5bf74 100644 --- a/src/driver/vfd.h +++ b/src/driver/vfd.h @@ -76,7 +76,7 @@ class CVFD private: -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 fp_display_caps_t caps; #endif MODES mode; diff --git a/src/drivertool.c b/src/drivertool.c index d756af2af..fda635966 100644 --- a/src/drivertool.c +++ b/src/drivertool.c @@ -32,7 +32,7 @@ #include -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 #ifdef HAVE_COOLSTREAM_CS_IR_GENERIC_H #include #endif diff --git a/src/eitd/edvbstring.cpp b/src/eitd/edvbstring.cpp index 90a5fbc38..20ec699e0 100644 --- a/src/eitd/edvbstring.cpp +++ b/src/eitd/edvbstring.cpp @@ -198,7 +198,7 @@ static unsigned long iso6937[96]={ 0x0138, 0x00E6, 0x0111, 0x00F0, 0x0127, 0x0131, 0x0133, 0x0140, 0x0142, 0x00F8, 0x0153, 0x00DF, 0x00FE, 0x0167, 0x014B, 0x00AD }; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 const unsigned short cGB2312UNI[] = { // Start at 0xA100.so index have to be reduced. Maybe this can be optimized by removing the starts but for // now just 'make it work' :). @@ -2020,7 +2020,7 @@ std::string convertDVBUTF8(const char *data, int len, int table, int tsidonid) { int newtable = 0; bool twochar = false; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 bool gb2312 = false; #endif if (!len) @@ -2070,7 +2070,7 @@ std::string convertDVBUTF8(const char *data, int len, int table, int tsidonid) break; case 0x13: ++i; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 //debug(DEBUG_NORMAL, "GB-2312-1980 enc."); gb2312 = true; #endif @@ -2116,7 +2116,7 @@ std::string convertDVBUTF8(const char *data, int len, int table, int tsidonid) //debug(DEBUG_INFO, "recode:::: doVideoTexSuppl code %lX", code); } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 // GB2312 -> Unicode if (gb2312 && !code) { if (data[i] >= 0xA1) { diff --git a/src/gui/audio_setup.cpp b/src/gui/audio_setup.cpp index b30ad0ca0..a9e6c5ac9 100644 --- a/src/gui/audio_setup.cpp +++ b/src/gui/audio_setup.cpp @@ -94,7 +94,7 @@ const CMenuOptionChooser::keyval AUDIOMENU_ANALOGOUT_OPTIONS[AUDIOMENU_ANALOGOUT { 2, LOCALE_AUDIOMENU_MONORIGHT } }; #if HAVE_CST_HARDWARE -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 #define AUDIOMENU_SRS_OPTION_COUNT 3 #else #define AUDIOMENU_SRS_OPTION_COUNT 2 @@ -103,7 +103,7 @@ const CMenuOptionChooser::keyval AUDIOMENU_SRS_OPTIONS[AUDIOMENU_SRS_OPTION_COUN { { 0 , LOCALE_AUDIO_SRS_ALGO_LIGHT }, { 1 , LOCALE_AUDIO_SRS_ALGO_NORMAL }, -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 { 2 , LOCALE_AUDIO_SRS_ALGO_HEAVY } #endif }; @@ -256,7 +256,7 @@ int CAudioSetup::showAudioSetup() audioSettings->addItem(GenericMenuSeparatorLine); audioSettings->addItem(as_oj_srsonoff); audioSettings->addItem(as_oj_algo); -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 audioSettings->addItem(as_oj_noise); #endif audioSettings->addItem(as_oj_volrev); @@ -272,7 +272,7 @@ int CAudioSetup::showAudioSetup() int res = audioSettings->exec(NULL, ""); selected = audioSettings->getSelected(); delete audioSettings; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 delete as_oj_noise; #endif CZapit::getInstance()->SetVolumePercent(g_settings.audio_volume_percent_ac3, g_settings.audio_volume_percent_pcm); diff --git a/src/gui/cam_menu.cpp b/src/gui/cam_menu.cpp index 9b6fda523..1065e9ab9 100644 --- a/src/gui/cam_menu.cpp +++ b/src/gui/cam_menu.cpp @@ -169,10 +169,10 @@ int CCAMMenuHandler::doMainMenu() #if 1 cammenu->addItem(new CMenuOptionChooser(LOCALE_CI_REC_ZAPTO, &g_settings.ci_rec_zapto, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true, this)); CMenuOptionChooser *ci_mode = new CMenuOptionChooser(LOCALE_CI_MODE, &g_settings.ci_mode, OPTIONS_CI_MODE_OPTIONS, OPTIONS_CI_MODE_OPTION_COUNT, true, NULL); - +// ci_mode->setHint(NEUTRINO_ICON_HINT_IMAGELOGO, LOCALE_MENU_HINT_CI_MODE); cammenu->addItem(ci_mode); #endif -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 int fecount = CFEManager::getInstance()->getFrontendCount(); char fename[fecount+1][255]; diff --git a/src/gui/movieplayer.cpp b/src/gui/movieplayer.cpp index 3efef83a9..a92451095 100644 --- a/src/gui/movieplayer.cpp +++ b/src/gui/movieplayer.cpp @@ -2435,7 +2435,7 @@ void CMoviePlayerGui::addAudioFormat(int count, std::string &apidtitle, bool& en case 6: /*DTS*/ if (apidtitle.find("DTS") == std::string::npos) apidtitle.append(" (DTS)"); -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 enabled = false; #endif break; diff --git a/src/gui/osd_helpers.cpp b/src/gui/osd_helpers.cpp index cd2c37521..903f75815 100644 --- a/src/gui/osd_helpers.cpp +++ b/src/gui/osd_helpers.cpp @@ -147,7 +147,7 @@ int COsdHelpers::isVideoSystem1080(int res) (res == VIDEO_STD_1080P25)) return true; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if ((res == VIDEO_STD_1080P50) || (res == VIDEO_STD_1080P60) || (res == VIDEO_STD_1080P2397) || diff --git a/src/gui/osd_setup.cpp b/src/gui/osd_setup.cpp index e5b732669..aca47f4d6 100644 --- a/src/gui/osd_setup.cpp +++ b/src/gui/osd_setup.cpp @@ -724,7 +724,18 @@ int COsdSetup::showOsdSetup() mc->setHint("", LOCALE_MENU_HINT_OSD_PRESET); osd_menu->addItem(mc); } +#if 0 +#if !defined BOXMODEL_CST_HD2 + int scart_osd_fix_exist = 0; + if (file_exists("/var/etc/.scart_osd_fix")) + scart_osd_fix_exist = 1; + CFlagFileNotifier * scartFileNotifier = new CFlagFileNotifier("scart_osd_fix"); + mc = new CMenuOptionChooser(LOCALE_SCART_OSD_FIX, &scart_osd_fix_exist, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, !g_settings.screen_preset, scartFileNotifier); + mc->setHint(NEUTRINO_ICON_HINT_IMAGELOGO, LOCALE_MENU_HINT_SCART_OSD_FIX); + osd_menu->addItem(mc); +#endif +#endif #if 0 // round corners mc = new CMenuOptionChooser(LOCALE_EXTRA_ROUNDED_CORNERS, &g_settings.theme.rounded_corners, MENU_CORNERSETTINGS_TYPE_OPTIONS, MENU_CORNERSETTINGS_TYPE_OPTION_COUNT, true, this); @@ -766,6 +777,9 @@ int COsdSetup::showOsdSetup() CAudioMute::getInstance()->enableMuteIcon(true); } +// #if !defined BOXMODEL_CST_HD2 +// delete scartFileNotifier; +// #endif delete colorInfoclockNotifier; delete screensaverNotifier; delete channellistNotifier; diff --git a/src/gui/streaminfo1.cpp b/src/gui/streaminfo1.cpp index 2444526d1..dcaab6e05 100644 --- a/src/gui/streaminfo1.cpp +++ b/src/gui/streaminfo1.cpp @@ -582,7 +582,7 @@ void CStreamInfo2::paint_techinfo(int xpos, int ypos) g_Font[font_info]->RenderString (xpos, ypos, box_width, buf, COL_MENUCONTENT_TEXT); cs_vs_format_t vsfn; videoDecoder->GetVideoSystemFormatName(&vsfn); -#ifdef BOXMODEL_CS_HD1 +#ifdef BOXMODEL_CST_HD1 snprintf(buf, sizeof(buf), "HDMI: %s%s", vsfn.format, #else snprintf(buf, sizeof(buf), "HDMI: %s, Scart/Cinch: %s%s", vsfn.formatHD, vsfn.formatSD, diff --git a/src/gui/update.cpp b/src/gui/update.cpp index 719e39987..03bbf98a7 100644 --- a/src/gui/update.cpp +++ b/src/gui/update.cpp @@ -105,7 +105,7 @@ extern int allow_flash; #else #define FILEBROWSER_UPDATE_FILTER "img" #define MTD_OF_WHOLE_IMAGE 0 -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 #define MTD_DEVICE_OF_UPDATE_PART "/dev/mtd0" #else #define MTD_DEVICE_OF_UPDATE_PART "/dev/mtd3" @@ -363,8 +363,8 @@ bool CFlashUpdate::selectHttpImage(void) file_md5 = md5s[selected]; fileType = fileTypes[selected]; gotImage = (fileType <= '9'); - -#if 0 //#ifdef BOXMODEL_CS_HD2 +//#ifdef BOXMODEL_CST_HD2 +#if 0 if (gotImage) { int esize = CMTDInfo::getInstance()->getMTDEraseSize(sysfs); @@ -607,7 +607,7 @@ int CFlashUpdate::exec(CMenuTarget* parent, const std::string &actionKey) if (fileType <= '9') // flashing image { #if ENABLE_EXTUPDATE -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 if (g_settings.apply_settings) { if (ShowMsg(LOCALE_MESSAGEBOX_INFO, LOCALE_FLASHUPDATE_APPLY_SETTINGS, CMsgBox::mbrYes, CMsgBox::mbYes | CMsgBox::mbNo, NEUTRINO_ICON_UPDATE) == CMsgBox::mbrYes) if (!CExtUpdate::getInstance()->applySettings(filename, CExtUpdate::MODE_SOFTUPDATE)) { @@ -781,7 +781,7 @@ CFlashExpert::CFlashExpert() { selectedMTD = -1; width = 40; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 forceOtherFilename = false; otherFilename = ""; createimage_other = 0; @@ -798,7 +798,7 @@ CFlashExpert* CFlashExpert::getInstance() bool CFlashExpert::checkSize(int mtd, std::string &backupFile) { -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 if (mtd < 0) return false; #endif char errMsg[1024] = {0}; @@ -812,7 +812,7 @@ bool CFlashExpert::checkSize(int mtd, std::string &backupFile) uint64_t btotal = 0, bused = 0; long bsize = 0; uint64_t backupRequiredSize = 0; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (mtd == -1) { // check disk space for image creation if (!get_fs_usage("/", btotal, bused, &bsize)) { snprintf(errMsg, sizeof(errMsg)-1, g_Locale->getText(LOCALE_FLASHUPDATE_READ_VOLUME_ERROR), "root0"); @@ -848,7 +848,7 @@ bool CFlashExpert::checkSize(int mtd, std::string &backupFile) return true; } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 bool CFlashExpert::readDevtableFile(std::string &devtableFile, CMkfsJFFS2::v_devtable_t &v_devtable) { FILE *fd = fopen(devtableFile.c_str(), "r"); @@ -934,7 +934,7 @@ void CFlashExpert::readmtd(int preadmtd) std::string tankStr = ""; #if ENABLE_EXTUPDATE -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 int eSize = CMTDInfo::getInstance()->getMTDEraseSize(CMTDInfo::getInstance()->findMTDsystem()); if (preadmtd == 0) { if (createimage_other == 0) { @@ -953,7 +953,7 @@ void CFlashExpert::readmtd(int preadmtd) #endif filename = (std::string)g_settings.update_dir + "/" + mtdInfo->getMTDName(preadmtd) + timeStr + tankStr + ".img"; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 std::string title = " (" + CMTDInfo::getInstance()->getMTDName(preadmtd) + ")"; std::string mountp = getJFFS2MountPoint(preadmtd); if (preadmtd == 0) { @@ -977,7 +977,7 @@ void CFlashExpert::readmtd(int preadmtd) } bool skipCheck = false; -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 if ((std::string)g_settings.update_dir == "/tmp") skipCheck = true; #else @@ -1005,7 +1005,7 @@ void CFlashExpert::readmtd(int preadmtd) sprintf(message, g_Locale->getText(LOCALE_FLASHUPDATE_SAVESUCCESS), filename.c_str()); sleep(1); hide(); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (!forceOtherFilename) ShowHint(LOCALE_MESSAGEBOX_INFO, message); #else @@ -1067,7 +1067,7 @@ int CFlashExpert::showMTDSelector(const std::string & actionkey) for(int lx=0;lxgetMTDCount();lx++) { char sActionKey[20]; bool enabled = true; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 // disable write uboot / uldr / env if ((actionkey == "writemtd") && (lx == mtdInfo->findMTDNumberFromName("u-boot") || lx == mtdInfo->findMTDNumberFromName("uldr") || @@ -1091,7 +1091,7 @@ int CFlashExpert::showMTDSelector(const std::string & actionkey) mtdselector->addItem(new CMenuForwarder(mtdInfo->getMTDName(lx).c_str(), enabled, NULL, this, sActionKey, CRCInput::convertDigitToKey(shortcut++))); } #if ENABLE_EXTUPDATE -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 if (actionkey == "writemtd") mtdselector->addItem(new CMenuForwarder("systemFS with settings", true, NULL, this, "writemtd10", CRCInput::convertDigitToKey(shortcut++))); #endif @@ -1184,7 +1184,7 @@ int CFlashExpert::exec(CMenuTarget* parent, const std::string & actionKey) return res; } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 CFlashExpertSetup::CFlashExpertSetup() { width = 40; @@ -1350,4 +1350,4 @@ int CFlashExpertSetup::showMenu() cfe->createimage_other = 0; return res; } -#endif // BOXMODEL_CS_HD2 +#endif // BOXMODEL_CST_HD2 diff --git a/src/gui/update.h b/src/gui/update.h index e46d3ae1f..ed90be6ce 100644 --- a/src/gui/update.h +++ b/src/gui/update.h @@ -38,7 +38,8 @@ #include -#ifdef BOXMODEL_CS_HD2 +//#include +#ifdef BOXMODEL_CST_HD2 #include #endif @@ -82,13 +83,13 @@ class CFlashExpert : public CProgressWindow int showFileSelector(const std::string & actionkey); bool checkSize(int mtd, std::string &backupFile); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 bool readDevtableFile(std::string &devtableFile, CMkfsJFFS2::v_devtable_t &v_devtable); void readmtdJFFS2(std::string &filename, std::string title="", std::string path="/", bool makeDevTable=true); #endif public: -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 bool forceOtherFilename; std::string otherFilename; int createimage_other; @@ -101,7 +102,7 @@ class CFlashExpert : public CProgressWindow }; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 class CFlashExpertSetup : public CMenuTarget { private: @@ -116,6 +117,6 @@ class CFlashExpertSetup : public CMenuTarget int exec(CMenuTarget* parent, const std::string &actionKey); }; -#endif // BOXMODEL_CS_HD2 +#endif // BOXMODEL_CST_HD2 #endif diff --git a/src/gui/update_ext.cpp b/src/gui/update_ext.cpp index f13c9ace1..4ca2054b9 100644 --- a/src/gui/update_ext.cpp +++ b/src/gui/update_ext.cpp @@ -233,7 +233,7 @@ bool CExtUpdate::applySettings() if (mtdFilename.empty()) return ErrorReset(0, "error system mtd not found"); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 uint64_t mtdSize = 65536*1024; // FIXME hack, mtd size more than free RAM #else uint64_t mtdSize = mtdInfo->getMTDSize(mtdFilename); diff --git a/src/gui/update_menue.cpp b/src/gui/update_menue.cpp index ea3d597ac..ebcee8e9a 100644 --- a/src/gui/update_menue.cpp +++ b/src/gui/update_menue.cpp @@ -88,7 +88,10 @@ int CSoftwareUpdate::showSoftwareUpdate() inetkey = CRCInput::convertDigitToKey(1); } +// bool allow_update = !CRecordManager::getInstance()->RecordingStatus() || CRecordManager::getInstance()->TimeshiftOnly(); + CFlashUpdate flash; + flash.enableNotify(false); //online update if (file_exists(g_settings.softupdate_url_file.c_str())) { update_item = new CMenuForwarder(LOCALE_FLASHUPDATE_CHECKUPDATE_INTERNET, true, NULL, &flash, "inet", inetkey); @@ -120,7 +123,7 @@ int CSoftwareUpdate::showSoftwareUpdate() unsigned int nextShortcut = (unsigned int)softUpdate.getNextShortcut(); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 softUpdate.addItem(GenericMenuSeparatorLine); mf = new CMenuDForwarder(LOCALE_FLASHUPDATE_CREATEIMAGE_MENU, true, NULL, new CFlashExpertSetup(), NULL, CRCInput::convertDigitToKey(nextShortcut)); diff --git a/src/gui/update_settings.cpp b/src/gui/update_settings.cpp index 89334905d..49b97fe7f 100644 --- a/src/gui/update_settings.cpp +++ b/src/gui/update_settings.cpp @@ -130,7 +130,7 @@ int CUpdateSettings::initMenu() CMenuOptionChooser *name_backup = new CMenuOptionChooser(LOCALE_FLASHUPDATE_NAMEMODE2, &g_settings.softupdate_name_mode_backup, SOFTUPDATE_NAME_MODE2_OPTIONS, SOFTUPDATE_NAME_MODE2_OPTION_COUNT, true); // name_backup->setHint("", LOCALE_MENU_HINT_XXX); -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 CMenuOptionChooser *apply_settings = new CMenuOptionChooser(LOCALE_FLASHUPDATE_MENU_APPLY_SETTINGS, &g_settings.apply_settings, OPTIONS_OFF0_ON1_OPTIONS, OPTIONS_OFF0_ON1_OPTION_COUNT, true, OnOffNotifier); // apply_settings->setHint("", LOCALE_MENU_HINT_XXX); @@ -154,7 +154,7 @@ int CUpdateSettings::initMenu() w_upsettings.addItem(fw_url); #if ENABLE_EXTUPDATE w_upsettings.addItem(name_backup); -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 w_upsettings.addItem(GenericMenuSeparatorLine); w_upsettings.addItem(apply_settings); w_upsettings.addItem(name_apply); diff --git a/src/gui/videosettings.cpp b/src/gui/videosettings.cpp index 25ccee0d1..af21a93f9 100644 --- a/src/gui/videosettings.cpp +++ b/src/gui/videosettings.cpp @@ -63,7 +63,7 @@ #include #include -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 #include #endif @@ -123,7 +123,7 @@ const CMenuOptionChooser::keyval VIDEOMENU_43MODE_OPTIONS[] = }; #define VIDEOMENU_43MODE_OPTION_COUNT (sizeof(VIDEOMENU_43MODE_OPTIONS)/sizeof(CMenuOptionChooser::keyval)) -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 #define VIDEOMENU_VIDEOSIGNAL_TD_OPTION_COUNT 2 const CMenuOptionChooser::keyval VIDEOMENU_VIDEOSIGNAL_TD_OPTIONS[VIDEOMENU_VIDEOSIGNAL_TD_OPTION_COUNT] = { @@ -235,7 +235,7 @@ CMenuOptionChooser::keyval_ext VIDEOMENU_VIDEOMODE_OPTIONS[VIDEOMENU_VIDEOMODE_O { -1, NONEXISTANT_LOCALE, "2160p 50Hz" }, { -1, NONEXISTANT_LOCALE, "Auto" } }; -#elif BOXMODEL_CS_HD1 +#elif BOXMODEL_CST_HD1 /* numbers corresponding to video.cpp from zapit */ CMenuOptionChooser::keyval_ext VIDEOMENU_VIDEOMODE_OPTIONS[VIDEOMENU_VIDEOMODE_OPTION_COUNT] = { @@ -260,7 +260,7 @@ CMenuOptionChooser::keyval_ext VIDEOMENU_VIDEOMODE_OPTIONS[VIDEOMENU_VIDEOMODE_O { -1, NONEXISTANT_LOCALE, "2160p 50Hz" }, { VIDEO_STD_AUTO, NONEXISTANT_LOCALE, "Auto" } }; -#elif BOXMODEL_CS_HD2 +#elif BOXMODEL_CST_HD2 /* numbers corresponding to video.cpp from zapit */ CMenuOptionChooser::keyval_ext VIDEOMENU_VIDEOMODE_OPTIONS[VIDEOMENU_VIDEOMODE_OPTION_COUNT] = { @@ -436,7 +436,7 @@ int CVideoSettings::showVideoSetup() } else if (system_rev > 0x06) { -#if defined(BOXMODEL_CS_HD2) && defined(ANALOG_MODE) +#if defined(BOXMODEL_CST_HD2) && defined(ANALOG_MODE) vs_analg_ch = new CMenuOptionChooser(LOCALE_VIDEOMENU_ANALOG_MODE, &g_settings.analog_mode1, VIDEOMENU_VIDEOSIGNAL_HD2_OPTIONS, VIDEOMENU_VIDEOSIGNAL_HD2_OPTION_COUNT, true, this); vs_analg_ch->setHint("", LOCALE_MENU_HINT_VIDEO_ANALOG_MODE); #else @@ -448,7 +448,7 @@ int CVideoSettings::showVideoSetup() vs_chinch_ch->setHint("", LOCALE_MENU_HINT_VIDEO_CINCH_MODE); #endif } -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 else if (g_info.hw_caps->has_SCART) /* TRIPLEDRAGON hack... :-) TODO: SPARK? */ { vs_scart_ch = new CMenuOptionChooser(LOCALE_VIDEOMENU_SCART, &g_settings.analog_mode1, VIDEOMENU_VIDEOSIGNAL_TD_OPTIONS, VIDEOMENU_VIDEOSIGNAL_TD_OPTION_COUNT, true, this); @@ -469,7 +469,7 @@ int CVideoSettings::showVideoSetup() CMenuOptionChooser *vs_dbdropt_ch = NULL; CMenuWidget videomodes(LOCALE_MAINSETTINGS_VIDEO, NEUTRINO_ICON_SETTINGS); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 CMenuForwarder * vs_automodes_fw = NULL; CMenuWidget automodes(LOCALE_MAINSETTINGS_VIDEO, NEUTRINO_ICON_SETTINGS); #endif @@ -497,7 +497,7 @@ int CVideoSettings::showVideoSetup() vs_videomodes_fw->setHint("", LOCALE_MENU_HINT_VIDEO_MODES); } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 automodes.addIntroItems(LOCALE_VIDEOMENU_ENABLED_MODES_AUTO); for (int i = 0; i < VIDEOMENU_VIDEOMODE_OPTION_COUNT - 1; i++) @@ -532,11 +532,11 @@ int CVideoSettings::showVideoSetup() videosetup->addItem(vs_dbdropt_ch); //dbdr options if (vs_videomodes_fw != NULL) videosetup->addItem(vs_videomodes_fw); //video modes submenue -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 videosetup->addItem(vs_automodes_fw); //video auto modes submenue #endif -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 /* values are from -128 to 127, but brightness really no sense after +/- 40. changeNotify multiply contrast and saturation to 3 */ CMenuOptionNumberChooser * bcont = new CMenuOptionNumberChooser(LOCALE_VIDEOMENU_BRIGHTNESS, &g_settings.brightness, true, -42, 42, this); bcont->setHint("", LOCALE_MENU_HINT_VIDEO_BRIGHTNESS); @@ -617,7 +617,7 @@ void CVideoSettings::setVideoSettings() videoDecoder->SetVideoMode((analog_mode_t) g_settings.analog_mode1); videoDecoder->SetVideoMode((analog_mode_t) g_settings.analog_mode2); #endif -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 changeNotify(LOCALE_VIDEOMENU_ANALOG_MODE, NULL); #else unsigned int system_rev = cs_get_revision(); @@ -642,7 +642,7 @@ void CVideoSettings::setVideoSettings() videoDecoder->SetDBDR(g_settings.video_dbdr); CAutoModeNotifier anotify; anotify.changeNotify(NONEXISTANT_LOCALE, 0); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 changeNotify(LOCALE_VIDEOMENU_BRIGHTNESS, NULL); changeNotify(LOCALE_VIDEOMENU_CONTRAST, NULL); changeNotify(LOCALE_VIDEOMENU_SATURATION, NULL); @@ -720,7 +720,7 @@ bool CVideoSettings::changeNotify(const neutrino_locale_t OptionName, void * /* setupVideoSystem(true/*ask*/); return true; } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 else if (ARE_LOCALES_EQUAL(OptionName, LOCALE_VIDEOMENU_BRIGHTNESS)) { videoDecoder->SetControl(VIDEO_CONTROL_BRIGHTNESS, g_settings.brightness); diff --git a/src/neutrino.cpp b/src/neutrino.cpp index a64399797..d71a4a310 100644 --- a/src/neutrino.cpp +++ b/src/neutrino.cpp @@ -847,7 +847,7 @@ int CNeutrinoApp::loadSetup(const char * fname) webtvsetup.webtv_xml_auto(); g_settings.webradio_xml_auto = configfile.getInt32("webradio_xml_auto", 1); g_settings.webradio_xml.clear(); -#ifndef BOXMODEL_CS_HD1 +#ifndef BOXMODEL_CST_HD1 /* Coolstream's HD1 generation can't play audiostreams via movieplayer because of driver- or firmware-issues or so. Not sure. @@ -1172,7 +1172,7 @@ int CNeutrinoApp::loadSetup(const char * fname) erg = 2; } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 g_settings.brightness = configfile.getInt32("brightness", 0); g_settings.contrast = configfile.getInt32("contrast", 0); g_settings.saturation = configfile.getInt32("saturation", 0); @@ -1953,7 +1953,7 @@ void CNeutrinoApp::saveSetup(const char * fname) configfile.setInt32("window_size", g_settings.window_size); configfile.setInt32("window_width", g_settings.window_width); configfile.setInt32("window_height", g_settings.window_height); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 configfile.setInt32("brightness", g_settings.brightness ); configfile.setInt32("contrast", g_settings.contrast ); configfile.setInt32("enable_sd_osd", g_settings.enable_sd_osd ); @@ -5146,6 +5146,10 @@ void stop_daemons(bool stopall, bool for_flash) CVFD::getInstance()->setMode(CVFD::MODE_TVRADIO); CVFD::getInstance()->ShowText("Stop daemons..."); g_settings.epg_scan_mode = CEpgScan::MODE_OFF; + +//#ifdef BOXMODEL_CST_HD2 +// system("/bin/backup_flash.sh"); //don't fork +//#endif my_system(NEUTRINO_ENTER_FLASH_SCRIPT); } diff --git a/src/system/Makefile.am b/src/system/Makefile.am index 9c05d303b..300c33317 100644 --- a/src/system/Makefile.am +++ b/src/system/Makefile.am @@ -1,4 +1,4 @@ -if BOXMODEL_CS_HD2 +if BOXMODEL_CST_HD2 SUBDIRS = mtdutils endif diff --git a/src/system/flashtool.cpp b/src/system/flashtool.cpp index f9ef08704..881e7f823 100644 --- a/src/system/flashtool.cpp +++ b/src/system/flashtool.cpp @@ -187,7 +187,7 @@ bool CFlashTool::program( const std::string & filename, int globalProgressEndEra std::string flashfile; bool skipCopy = false; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (strcmp(dn, "/tmp") != 0) { uint64_t btotal = 0, bused = 0; long bsize = 0; @@ -697,7 +697,7 @@ int CMTDInfo::getMTDEraseSize( const std::string & filename ) std::string CMTDInfo::findMTDsystem() { -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 std::string sysfs = "root0"; #else std::string sysfs = "systemFS"; diff --git a/src/system/setting_helpers.cpp b/src/system/setting_helpers.cpp index 6ed30fa28..d3b48ad7c 100644 --- a/src/system/setting_helpers.cpp +++ b/src/system/setting_helpers.cpp @@ -554,7 +554,7 @@ int CDataResetNotifier::exec(CMenuTarget* /*parent*/, const std::string& actionK CServiceManager::getInstance()->SatelliteList().clear(); CZapit::getInstance()->LoadSettings(); CZapit::getInstance()->GetConfig(zapitCfg); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 /* flag file to erase /var partition on factory reset, will be done by init scripts */ FILE * fp = fopen("/var_init/etc/.reset", "w"); @@ -593,7 +593,7 @@ int CDataResetNotifier::exec(CMenuTarget* /*parent*/, const std::string& actionK void CFanControlNotifier::setSpeed(unsigned int speed) { printf("FAN Speed %d\n", speed); -#ifndef BOXMODEL_CS_HD2 +#ifndef BOXMODEL_CST_HD2 int cfd = open("/dev/cs_control", O_RDONLY); if(cfd < 0) { perror("Cannot open /dev/cs_control"); @@ -653,7 +653,8 @@ bool CAutoModeNotifier::changeNotify(const neutrino_locale_t /*OptionName*/, voi i, VIDEOMENU_VIDEOMODE_OPTIONS[i].key, VIDEO_STD_MAX); continue; } -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 + for(i = 0; i < VIDEOMENU_VIDEOMODE_OPTION_COUNT; i++) modes[VIDEOMENU_VIDEOMODE_OPTIONS[i].key] = g_settings.enabled_auto_modes[i]; #else modes[VIDEOMENU_VIDEOMODE_OPTIONS[i].key] = g_settings.enabled_video_modes[i]; diff --git a/src/system/settings.h b/src/system/settings.h index e36a3c948..a476eea13 100644 --- a/src/system/settings.h +++ b/src/system/settings.h @@ -303,7 +303,7 @@ struct SNeutrinoSettings int psi_step; #endif -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 int brightness; int contrast; int saturation; diff --git a/src/zapit/src/capmt.cpp b/src/zapit/src/capmt.cpp index bdf31f841..f9a35665b 100644 --- a/src/zapit/src/capmt.cpp +++ b/src/zapit/src/capmt.cpp @@ -363,7 +363,7 @@ bool CCamManager::SetMode(t_channel_id channel_id, enum runmode mode, bool start //channel->setRawPmt(NULL);//FIXME #if HAVE_CST_HARDWARE StopCam(channel_id, cam); -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 // hack for rezaping to the recording channel CZapitChannel * chan = CServiceManager::getInstance()->GetCurrentChannel(); @@ -396,7 +396,7 @@ bool CCamManager::SetMode(t_channel_id channel_id, enum runmode mode, bool start if (channel_map.size() > 1) list = CCam::CAPMT_ADD; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 int ci_use_count = 0; for (it = channel_map.begin(); it != channel_map.end(); ++it) { @@ -477,7 +477,7 @@ bool CCamManager::SetMode(t_channel_id channel_id, enum runmode mode, bool start void CCamManager::SetCITuner(int tuner) { tunerno = tuner; -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (tunerno >= 0) cCA::GetInstance()->SetTS((CA_DVBCI_TS_INPUT)tunerno); #endif diff --git a/src/zapit/src/zapit.cpp b/src/zapit/src/zapit.cpp index 2e6d5a232..55da7b5ed 100644 --- a/src/zapit/src/zapit.cpp +++ b/src/zapit/src/zapit.cpp @@ -610,7 +610,7 @@ bool CZapit::ZapIt(const t_channel_id channel_id, bool forupdate, bool startplay StopPip(); #endif -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 if (CCamManager::getInstance()->GetCITuner() < 0) cCA::GetInstance()->SetTS((CA_DVBCI_TS_INPUT)live_fe->getNumber()); #endif @@ -2499,7 +2499,7 @@ bool CZapit::Start(Z_start_arg *ZapStart_arg) /* FIXME until proper demux management */ int dnum = 1; #endif -#ifdef BOXMODEL_CS_HD2 +#ifdef BOXMODEL_CST_HD2 videoDecoder = cVideo::GetDecoder(0); audioDecoder = cAudio::GetDecoder(0);