Merge branch 'cst-next' of git://coolstreamtech.de/cst-public-gui-neutrino into ni/cst-next

Conflicts:
	src/gui/epgview.cpp
	src/gui/infoviewer.cpp
	src/gui/moviebrowser.cpp
	src/gui/movieplayer.cpp


Origin commit data
------------------
Commit: f49da45cc7
Author: vanhofen <vanhofen@gmx.de>
Date: 2016-08-02 (Tue, 02 Aug 2016)
This commit is contained in:
vanhofen
2016-08-02 11:43:59 +02:00
4 changed files with 40 additions and 41 deletions

View File

@@ -557,7 +557,7 @@ int CEpgData::show_mp(MI_MOVIE_INFO *mp_movie_info, int /*mp_position*/, int /*m
} }
#endif #endif
int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_startzeit, bool doLoop, bool callFromfollowlist,bool mp_info ) int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_startzeit, bool doLoop, bool callFromfollowlist, bool mp_info )
{ {
int res = menu_return::RETURN_REPAINT; int res = menu_return::RETURN_REPAINT;
static uint64_t id = 0; static uint64_t id = 0;
@@ -576,8 +576,8 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
CZapitChannel * channel = CServiceManager::getInstance()->FindChannel(channel_id); CZapitChannel * channel = CServiceManager::getInstance()->FindChannel(channel_id);
if (channel) if (channel)
epg_id = channel->getEpgID(); epg_id = channel->getEpgID();
if(!mp_info) if (!mp_info)
GetEPGData(epg_id, id, &startzeit ); GetEPGData(epg_id, id, &startzeit);
epgTextSwitch.clear(); epgTextSwitch.clear();
if (doLoop) if (doLoop)
@@ -793,10 +793,10 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
textCount = epgText.size(); textCount = epgText.size();
showText(showPos, sy + toph); showText(showPos, sy + toph);
// show Timer Event Buttons // show Timer Event Buttons
showTimerEventBar (true, isCurrentEPG(channel_id), mp_info); showTimerEventBar(true, isCurrentEPG(channel_id), mp_info);
//show progressbar //show progressbar
if ( !mp_info && epg_done!= -1 ) if (!mp_info && epg_done!= -1)
{ {
int pbx = sx + 10 + widthl + 10 + ((ox-104-widthr-widthl-10-10-20)>>1); int pbx = sx + 10 + widthl + 10 + ((ox-104-widthr-widthl-10-10-20)>>1);
CProgressBar pb(pbx, sy+oy-height, 104, height-6); CProgressBar pb(pbx, sy+oy-height, 104, height-6);
@@ -840,23 +840,24 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
switch ( msg ) switch ( msg )
{ {
case NeutrinoMessages::EVT_TIMER: case NeutrinoMessages::EVT_TIMER:
if(!mp_info){ if (!mp_info)
if (data == g_InfoViewer->getUpdateTimer()) { {
GetEPGData(channel_id, id, &startzeit, false); if (data == g_InfoViewer->getUpdateTimer()) {
if ( epg_done!= -1 ) { GetEPGData(channel_id, id, &startzeit, false);
int pbx = sx + 10 + widthl + 10 + ((ox-104-widthr-widthl-10-10-20)>>1); if ( epg_done!= -1 ) {
CProgressBar pb(pbx, sy+oy-height, 104, height-6); int pbx = sx + 10 + widthl + 10 + ((ox-104-widthr-widthl-10-10-20)>>1);
pb.setType(CProgressBar::PB_TIMESCALE); CProgressBar pb(pbx, sy+oy-height, 104, height-6);
pb.setValues(epg_done, 100); pb.setType(CProgressBar::PB_TIMESCALE);
pb.paint(false); pb.setValues(epg_done, 100);
pb.paint(false);
}
} }
} if (data == fader.GetFadeTimer()) {
if(data == fader.GetFadeTimer()) { if (fader.FadeDone())
if(fader.FadeDone()) loop = false;
loop = false; }
} else
else CNeutrinoApp::getInstance()->handleMsg(msg, data);
CNeutrinoApp::getInstance()->handleMsg(msg, data);
} }
break; break;
case NeutrinoMessages::EVT_CURRENTNEXT_EPG: case NeutrinoMessages::EVT_CURRENTNEXT_EPG:
@@ -880,7 +881,6 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
showPos=0; showPos=0;
} }
break; break;
case CRCInput::RC_right: case CRCInput::RC_right:
//NI //NI
if(imdb_activ) if(imdb_activ)
@@ -895,7 +895,6 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
showPos=0; showPos=0;
} }
break; break;
case CRCInput::RC_down: case CRCInput::RC_down:
//NI //NI
if(imdb_activ) if(imdb_activ)
@@ -907,7 +906,6 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
showText(showPos, sy + toph, tmdbtoggle, false); showText(showPos, sy + toph, tmdbtoggle, false);
} }
break; break;
case CRCInput::RC_up: case CRCInput::RC_up:
//NI //NI
if(imdb_activ) if(imdb_activ)
@@ -942,14 +940,14 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
showTimerEventBar(true, true); showTimerEventBar(true, true);
} }
break; break;
// 31.05.2002 dirch record timer
case CRCInput::RC_red: case CRCInput::RC_red:
if (mp_info){ if (mp_info)
{
epgTextSwitchClear = false; epgTextSwitchClear = false;
loop = false; loop = false;
break; break;
}else if (!g_settings.minimode && (g_settings.recording_type != CNeutrinoApp::RECORDING_OFF)) }
else if (!g_settings.minimode && (g_settings.recording_type != CNeutrinoApp::RECORDING_OFF))
{ {
std::string recDir; std::string recDir;
//CTimerdClient timerdclient; //CTimerdClient timerdclient;
@@ -1061,7 +1059,8 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
epgText = epgText_saved; epgText = epgText_saved;
textCount = epgText.size(); textCount = epgText.size();
} }
if (g_settings.tmdb_api_key != "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"){ if (g_settings.tmdb_api_key != "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX")
{
showPos = 0; showPos = 0;
if (!tmdbtoggle) { if (!tmdbtoggle) {
cTmdb* tmdb = new cTmdb(epgData.title); cTmdb* tmdb = new cTmdb(epgData.title);
@@ -1124,10 +1123,10 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
} }
break; break;
} }
// 31.05.2002 dirch zapto timer
case CRCInput::RC_yellow: case CRCInput::RC_yellow:
{ {
if (!mp_info){ if (!mp_info)
{
if (isCurrentEPG(channel_id)) if (isCurrentEPG(channel_id))
{ {
CAdZapMenu::getInstance()->exec(NULL, "enable"); CAdZapMenu::getInstance()->exec(NULL, "enable");
@@ -1206,7 +1205,6 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
show(channel_id, id, &startzeit, false, call_fromfollowlist); show(channel_id, id, &startzeit, false, call_fromfollowlist);
showPos=0; showPos=0;
break; break;
case CRCInput::RC_info: //NI case CRCInput::RC_info: //NI
case CRCInput::RC_ok: case CRCInput::RC_ok:
case CRCInput::RC_timeout: case CRCInput::RC_timeout:
@@ -1224,9 +1222,7 @@ int CEpgData::show(const t_channel_id channel_id, uint64_t a_id, time_t* a_start
loop = false; loop = false;
} }
break; break;
default: default:
// konfigurierbare Keys handlen...
if (msg == (neutrino_msg_t)g_settings.key_channelList_cancel) { if (msg == (neutrino_msg_t)g_settings.key_channelList_cancel) {
if(fader.StartFadeOut()) { if(fader.StartFadeOut()) {
timeoutEnd = CRCInput::calcTimeoutEnd( 1 ); timeoutEnd = CRCInput::calcTimeoutEnd( 1 );
@@ -1431,7 +1427,6 @@ struct button_label EpgButtons[] = //NI
}; };
void CEpgData::showTimerEventBar (bool pshow, bool adzap, bool mp_info) void CEpgData::showTimerEventBar (bool pshow, bool adzap, bool mp_info)
{ {
int x,y,h,fh; int x,y,h,fh;
int icol_w, icol_h; int icol_w, icol_h;

View File

@@ -1087,7 +1087,7 @@ void CInfoViewer::loop(bool show_dot)
} }
else else
#endif #endif
g_RCInput->postMsg (NeutrinoMessages::SHOW_EPG, 0); g_RCInput->postMsg (NeutrinoMessages::SHOW_EPG, 0);
res = messages_return::cancel_info; res = messages_return::cancel_info;
} else if ((msg == NeutrinoMessages::EVT_TIMER) && (data == fader.GetFadeTimer())) { } else if ((msg == NeutrinoMessages::EVT_TIMER) && (data == fader.GetFadeTimer())) {
if(fader.FadeDone()) if(fader.FadeDone())

View File

@@ -1947,14 +1947,18 @@ bool CMovieBrowser::onButtonPressMainFrame(neutrino_msg_t msg)
{ {
if (m_movieSelectionHandler != NULL) { if (m_movieSelectionHandler != NULL) {
std::string fname = getScreenshotName(m_movieSelectionHandler->file.Name, S_ISDIR(m_movieSelectionHandler->file.Mode)); std::string fname = getScreenshotName(m_movieSelectionHandler->file.Name, S_ISDIR(m_movieSelectionHandler->file.Mode));
if (!fname.empty()){ if (!fname.empty())
{
//delete Cover //delete Cover
if (ShowMsg(LOCALE_MESSAGEBOX_INFO, LOCALE_MOVIEBROWSER_DELETE_SCREENSHOT, CMessageBox::mbrNo, CMessageBox:: mbYes | CMessageBox::mbNo) == CMessageBox::mbrYes) { if (ShowMsg(LOCALE_MESSAGEBOX_INFO, LOCALE_MOVIEBROWSER_DELETE_SCREENSHOT, CMessageBox::mbrNo, CMessageBox:: mbYes | CMessageBox::mbNo) == CMessageBox::mbrYes)
unlink(fname.c_str()); {
unlink(fname.c_str());
refresh(); refresh();
} }
}
#if 0 #if 0
}else if (g_settings.tmdb_api_key != "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"){ else if (g_settings.tmdb_api_key != "XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX")
{
//add TMDB Cover //add TMDB Cover
fname = m_movieSelectionHandler->file.Name.c_str(); fname = m_movieSelectionHandler->file.Name.c_str();
int ext_pos = 0; int ext_pos = 0;

View File

@@ -1569,7 +1569,7 @@ void CMoviePlayerGui::PlayFileLoop(void)
} }
else else
#endif #endif
callInfoViewer(); callInfoViewer();
update_lcd = true; update_lcd = true;
clearSubtitle(); clearSubtitle();
} else if (timeshift != TSHIFT_MODE_OFF && (msg == CRCInput::RC_text || msg == CRCInput::RC_epg || msg == NeutrinoMessages::SHOW_EPG)) { } else if (timeshift != TSHIFT_MODE_OFF && (msg == CRCInput::RC_text || msg == CRCInput::RC_epg || msg == NeutrinoMessages::SHOW_EPG)) {