From e1c39d4ce5e32451a275d2efff9f332542950446 Mon Sep 17 00:00:00 2001 From: mws Date: Tue, 29 Dec 2009 11:44:31 +0000 Subject: [PATCH] fix initializers and shadows git-svn-id: file:///home/bas/coolstream_public_svn/THIRDPARTY/applications/neutrino-experimental@122 e54a6e83-5905-42d5-8d5c-058d10e6a962 --- src/gui/audio_select.cpp | 6 +++--- src/gui/imageinfo.cpp | 8 ++++---- src/gui/plugins.cpp | 3 ++- src/gui/streaminfo2.cpp | 20 ++++++++++---------- 4 files changed, 19 insertions(+), 18 deletions(-) diff --git a/src/gui/audio_select.cpp b/src/gui/audio_select.cpp index 65aa07a25..73c693f3a 100644 --- a/src/gui/audio_select.cpp +++ b/src/gui/audio_select.cpp @@ -56,9 +56,9 @@ int dvbsub_getpid(); #define AUDIOMENU_ANALOGOUT_OPTION_COUNT 3 const CMenuOptionChooser::keyval AUDIOMENU_ANALOGOUT_OPTIONS[AUDIOMENU_ANALOGOUT_OPTION_COUNT] = { - { 0, LOCALE_AUDIOMENU_STEREO }, - { 1, LOCALE_AUDIOMENU_MONOLEFT }, - { 2, LOCALE_AUDIOMENU_MONORIGHT } + { 0, LOCALE_AUDIOMENU_STEREO ,0 }, + { 1, LOCALE_AUDIOMENU_MONOLEFT ,0 }, + { 2, LOCALE_AUDIOMENU_MONORIGHT ,0} }; int CAudioSelectMenuHandler::exec(CMenuTarget* parent, const std::string &/*actionkey*/) diff --git a/src/gui/imageinfo.cpp b/src/gui/imageinfo.cpp index 9f0aeb658..2cc8c430d 100644 --- a/src/gui/imageinfo.cpp +++ b/src/gui/imageinfo.cpp @@ -121,11 +121,11 @@ void CImageInfo::hide() videoDecoder->Pig(-1, -1, -1, -1); } -void CImageInfo::paint_pig(int x, int y, int w, int h) +void CImageInfo::paint_pig(int px, int py, int w, int h) { - //frameBuffer->paintBoxRel(x,y,w,h, COL_BACKGROUND); - frameBuffer->paintBackgroundBoxRel(x,y,w,h); - videoDecoder->Pig(x, y, w, h, frameBuffer->getScreenWidth(true), frameBuffer->getScreenHeight(true)); + //frameBuffer->paintBoxRel(px,py,w,h, COL_BACKGROUND); + frameBuffer->paintBackgroundBoxRel(px,py,w,h); + videoDecoder->Pig(px, py, w, h, frameBuffer->getScreenWidth(true), frameBuffer->getScreenHeight(true)); } void CImageInfo::paintLine(int xpos, int font, const char* text) diff --git a/src/gui/plugins.cpp b/src/gui/plugins.cpp index 3a713ea50..f55329a79 100644 --- a/src/gui/plugins.cpp +++ b/src/gui/plugins.cpp @@ -175,7 +175,8 @@ bool CPlugins::parseCfg(plugin *plugin_data) inFile.open(plugin_data->cfgfile.c_str()); - while (linecount < 20 && getline(inFile, line[linecount++])); + while (linecount < 20 && getline(inFile, line[linecount++])) + {}; plugin_data->fb = false; plugin_data->rc = false; diff --git a/src/gui/streaminfo2.cpp b/src/gui/streaminfo2.cpp index d3e98a276..8923e4795 100644 --- a/src/gui/streaminfo2.cpp +++ b/src/gui/streaminfo2.cpp @@ -277,11 +277,11 @@ void CStreamInfo2::hide () frameBuffer->paintBackgroundBoxRel (0, 0, max_width, max_height); } -void CStreamInfo2::paint_pig (int x, int y, int w, int h) +void CStreamInfo2::paint_pig (int px, int py, int w, int h) { - frameBuffer->paintBackgroundBoxRel (x, y, w, h); -printf("CStreamInfo2::paint_pig x %d y %d w %d h %d\n", x, y, w, h); - videoDecoder->Pig(x, y, w, h, frameBuffer->getScreenWidth(true), frameBuffer->getScreenHeight(true)); + frameBuffer->paintBackgroundBoxRel (px,py, w, h); +printf("CStreamInfo2::paint_pig x %d y %d w %d h %d\n", px, py, w, h); + videoDecoder->Pig(px, py, w, h, frameBuffer->getScreenWidth(true), frameBuffer->getScreenHeight(true)); } void CStreamInfo2::paint_signal_fe_box(int _x, int _y, int w, int h) @@ -538,8 +538,8 @@ void CStreamInfo2::paint_techinfo(int xpos, int ypos) //AUDIOTYPE ypos += iheight; - int type, layer, freq, mode, bitrate; - audioDecoder->getAudioInfo(type, layer, freq, bitrate, mode); + int type, layer, freq, mode, lbitrate; + audioDecoder->getAudioInfo(type, layer, freq, lbitrate, mode); #if 0 const char *layernames[4] = { "res", "III", "II", "I" }; const char *sampfreqnames[4] = { "44,1k", "48k", "32k", "res" }; @@ -641,17 +641,17 @@ void CStreamInfo2::paint_techinfo(int xpos, int ypos) sprintf((char*) buf, "%s", g_Locale->getText(LOCALE_STREAMINFO_NOT_AVAILABLE)); } else { unsigned int sw=spaceoffset; - for (unsigned int i= 0; (icurrent_PIDs.APIDs.size()) && (i<10); i++) + for (unsigned int li= 0; (licurrent_PIDs.APIDs.size()) && (li<10); li++) { - sprintf((char*) buf, "0x%04x (%i)", g_RemoteControl->current_PIDs.APIDs[i].pid, g_RemoteControl->current_PIDs.APIDs[i].pid ); - if (i == g_RemoteControl->current_PIDs.PIDs.selected_apid){ + sprintf((char*) buf, "0x%04x (%i)", g_RemoteControl->current_PIDs.APIDs[li].pid, g_RemoteControl->current_PIDs.APIDs[li].pid ); + if (li == g_RemoteControl->current_PIDs.PIDs.selected_apid){ g_Font[font_small]->RenderString(xpos+sw, ypos, width*2/3-10, buf, COL_MENUHEAD, 0, true); // UTF-8 } else{ g_Font[font_small]->RenderString(xpos+sw, ypos, width*2/3-10, buf, COL_MENUCONTENTDARK, 0, true); // UTF-8 } sw = g_Font[font_small]->getRenderWidth(buf)+sw+10; - if (((i+1)%3 == 0) &&(g_RemoteControl->current_PIDs.APIDs.size()-1 > i)){ // if we have lots of apids, put "intermediate" line with pids + if (((li+1)%3 == 0) &&(g_RemoteControl->current_PIDs.APIDs.size()-1 > li)){ // if we have lots of apids, put "intermediate" line with pids ypos+= sheight; sw=spaceoffset; }