gui/timerlist: fix display of channel name

Signed-off-by: M. Liebmann <tuxcode.bbg@gmail.com>


Origin commit data
------------------
Branch: ni/coolstream
Commit: 86fca10909
Author: martii <m4rtii@gmx.de>
Date: 2014-01-29 (Wed, 29 Jan 2014)



------------------
This commit was generated by Migit
This commit is contained in:
martii
2014-01-29 20:06:31 +01:00
committed by Michael Liebmann
parent 5f6a4bd32f
commit b6b67e2d5e
2 changed files with 4 additions and 4 deletions

View File

@@ -321,7 +321,7 @@ int CTimerList::exec(CMenuTarget* parent, const std::string & actionKey)
else if (timerNew.eventType == CTimerd::TIMER_ZAPTO || else if (timerNew.eventType == CTimerd::TIMER_ZAPTO ||
timerNew.eventType == CTimerd::TIMER_RECORD) timerNew.eventType == CTimerd::TIMER_RECORD)
{ {
if (strcmp(timerNew_channel_name, "---")==0) if (timerNew_channel_name == "---")
return menu_return::RETURN_REPAINT; return menu_return::RETURN_REPAINT;
if (timerNew.eventType==CTimerd::TIMER_RECORD) if (timerNew.eventType==CTimerd::TIMER_RECORD)
{ {
@@ -369,7 +369,7 @@ int CTimerList::exec(CMenuTarget* parent, const std::string & actionKey)
"%n", "%n",
&timerNew.channel_id, &timerNew.channel_id,
&delta); &delta);
strncpy(timerNew_channel_name, &(key[3 + delta + 1]), 29); timerNew_channel_name = std::string(key + 3 + delta + 1);
g_RCInput->postMsg(CRCInput::RC_timeout, 0); // leave underlying menu also g_RCInput->postMsg(CRCInput::RC_timeout, 0); // leave underlying menu also
g_RCInput->postMsg(CRCInput::RC_timeout, 0); // leave underlying menu also g_RCInput->postMsg(CRCInput::RC_timeout, 0); // leave underlying menu also
return menu_return::RETURN_EXIT; return menu_return::RETURN_EXIT;
@@ -1211,7 +1211,7 @@ int CTimerList::newTimer()
CMenuWidget mm(LOCALE_TIMERLIST_MODESELECT, NEUTRINO_ICON_SETTINGS); CMenuWidget mm(LOCALE_TIMERLIST_MODESELECT, NEUTRINO_ICON_SETTINGS);
mm.addItem(new CMenuForwarder(LOCALE_TIMERLIST_MODETV, true, NULL, &mctv)); mm.addItem(new CMenuForwarder(LOCALE_TIMERLIST_MODETV, true, NULL, &mctv));
mm.addItem(new CMenuForwarder(LOCALE_TIMERLIST_MODERADIO, true, NULL, &mcradio)); mm.addItem(new CMenuForwarder(LOCALE_TIMERLIST_MODERADIO, true, NULL, &mcradio));
strcpy(timerNew_channel_name,"---"); timerNew_channel_name = "---";
CMenuForwarder* m6 = new CMenuForwarder(LOCALE_TIMERLIST_CHANNEL, true, timerNew_channel_name, &mm); CMenuForwarder* m6 = new CMenuForwarder(LOCALE_TIMERLIST_CHANNEL, true, timerNew_channel_name, &mm);
CMenuForwarder* m7 = new CMenuForwarder(LOCALE_TIMERLIST_RECORDING_DIR, true,timerNew.recordingDir, this, "rec_dir2", CRCInput::RC_green, NEUTRINO_ICON_BUTTON_GREEN); CMenuForwarder* m7 = new CMenuForwarder(LOCALE_TIMERLIST_RECORDING_DIR, true,timerNew.recordingDir, this, "rec_dir2", CRCInput::RC_green, NEUTRINO_ICON_BUTTON_GREEN);

View File

@@ -63,7 +63,7 @@ class CTimerList : public CMenuTarget
CTimerd::TimerList timerlist; // List of timers CTimerd::TimerList timerlist; // List of timers
CTimerd::responseGetTimer timerNew; CTimerd::responseGetTimer timerNew;
int timerNew_standby_on; int timerNew_standby_on;
char timerNew_channel_name[30]; std::string timerNew_channel_name;
std::string m_weekdaysStr; std::string m_weekdaysStr;
int timer_apids_dflt; int timer_apids_dflt;