signalbars: add missing parameters for signal type names

This commit is contained in:
2015-12-30 16:56:45 +01:00
parent f5fba42118
commit 06686334bf
2 changed files with 6 additions and 6 deletions

View File

@@ -252,7 +252,7 @@ void CSignalNoiseRatioBar::Refresh()
//********************************************************************************************************************** //**********************************************************************************************************************
CSignalBox::CSignalBox(const int& xpos, const int& ypos, const int& w, const int& h, CFrontend *frontend_ref, const bool vert, CComponentsForm *parent) CSignalBox::CSignalBox(const int& xpos, const int& ypos, const int& w, const int& h, CFrontend *frontend_ref, const bool vert, CComponentsForm *parent, const std::string& sig_name, const std::string& snr_name)
{ {
initVarSigBox(); initVarSigBox();
vertical = vert; vertical = vert;
@@ -271,11 +271,11 @@ CSignalBox::CSignalBox(const int& xpos, const int& ypos, const int& w, const int
sbx_bar_width = width/2-2*corner_rad; sbx_bar_width = width/2-2*corner_rad;
} }
sbar = new CSignalBar(sbx_bar_x, 0, sbx_bar_width, sbx_bar_height, sbx_frontend); sbar = new CSignalBar(sbx_bar_x, 0, sbx_bar_width, sbx_bar_height, sbx_frontend, sig_name);
sbar->doPaintBg(false); sbar->doPaintBg(false);
addCCItem(sbar); addCCItem(sbar);
snrbar = new CSignalNoiseRatioBar(vertical ? sbx_bar_x : CC_APPEND, vertical ? CC_APPEND : 0, sbx_bar_width, sbx_bar_height, sbx_frontend); snrbar = new CSignalNoiseRatioBar(vertical ? sbx_bar_x : CC_APPEND, vertical ? CC_APPEND : 0, sbx_bar_width, sbx_bar_height, sbx_frontend, snr_name);
snrbar->doPaintBg(false); snrbar->doPaintBg(false);
addCCItem(snrbar); addCCItem(snrbar);

View File

@@ -160,8 +160,8 @@ class CSignalNoiseRatioBar : public CSignalBar
CSignalNoiseRatioBar(CComponentsForm *parent = NULL) CSignalNoiseRatioBar(CComponentsForm *parent = NULL)
: CSignalBar(parent){}; : CSignalBar(parent){};
///basic component class constructor for signal noise ratio. ///basic component class constructor for signal noise ratio.
CSignalNoiseRatioBar(const int& xpos, const int& ypos, const int& w, const int& h, CFrontend *frontend_ref, CComponentsForm *parent = NULL) CSignalNoiseRatioBar(const int& xpos, const int& ypos, const int& w, const int& h, CFrontend *frontend_ref, const std::string& snr_name = "SNR", CComponentsForm *parent = NULL)
: CSignalBar(xpos, ypos, w, h, frontend_ref, "SNR", parent){}; : CSignalBar(xpos, ypos, w, h, frontend_ref, snr_name, parent){};
}; };
/// Class CSignalBox() provides CSignalBar(), CSignalNoiseRatioBar() scales at once. /// Class CSignalBox() provides CSignalBar(), CSignalNoiseRatioBar() scales at once.
@@ -269,7 +269,7 @@ class CSignalBox : public CComponentsForm
public: public:
///class constructor for signal noise ratio. ///class constructor for signal noise ratio.
CSignalBox(const int& xpos, const int& ypos, const int& w, const int& h, CFrontend *frontend_ref = NULL, const bool vertical = true, CComponentsForm *parent = NULL); CSignalBox(const int& xpos, const int& ypos, const int& w, const int& h, CFrontend *frontend_ref = NULL, const bool vertical = true, CComponentsForm *parent = NULL, const std::string& sig_name = "SIG", const std::string& snr_name = "SNR" );
///returns the signal object, type = CSignalBar* ///returns the signal object, type = CSignalBar*
CSignalBar* getScaleObject(){return sbar;}; CSignalBar* getScaleObject(){return sbar;};