mirror of
https://github.com/tuxbox-fork-migrations/recycled-ni-neutrino.git
synced 2025-09-02 02:11:04 +02:00
gui/components: CSignalBox: allow for horizontal arrangement; add methods to retrieve current value
Signed-off-by: Thilo Graf <dbt@novatux.de>
Origin commit data
------------------
Branch: ni/coolstream
Commit: fbbb0ac57d
Author: martii <m4rtii@gmx.de>
Date: 2013-12-18 (Wed, 18 Dec 2013)
------------------
This commit was generated by Migit
This commit is contained in:
@@ -139,6 +139,9 @@ class CSignalBar : public CComponentsForm
|
||||
|
||||
///paint this items
|
||||
virtual void paint(bool do_save_bg);
|
||||
|
||||
//returns the current signal value
|
||||
uint16_t getValue(void) { return sb_signal; }
|
||||
};
|
||||
|
||||
/// Sub class of CSignalBar()
|
||||
@@ -256,6 +259,9 @@ class CSignalBox : public CComponentsForm
|
||||
///allowed width of scale bar from full width in %, rest used by caption, default value = 60% of width, use setScaleWidth() to set this value
|
||||
short sbx_scale_w_percent;
|
||||
|
||||
// true if vertical arrangement, false if horizontal
|
||||
bool vertical;
|
||||
|
||||
///initialize all needed basic attributes and objects
|
||||
void initVarSigBox();
|
||||
///initialize general properties of signal items
|
||||
@@ -266,7 +272,7 @@ class CSignalBox : public CComponentsForm
|
||||
|
||||
public:
|
||||
///class constructor for signal noise ratio.
|
||||
CSignalBox(const int& xpos, const int& ypos, const int& w, const int& h, CFrontend *frontend_ref);
|
||||
CSignalBox(const int& xpos, const int& ypos, const int& w, const int& h, CFrontend *frontend_ref, const bool vertical = true);
|
||||
|
||||
///returns the signal object, type = CSignalBar*
|
||||
CSignalBar* getScaleObject(){return sbar;};
|
||||
@@ -283,6 +289,14 @@ class CSignalBox : public CComponentsForm
|
||||
|
||||
///paint items
|
||||
void paint(bool do_save_bg);
|
||||
|
||||
///return current signal value
|
||||
uint16_t getSignalValue(void) { return sbar->getValue();}
|
||||
|
||||
///return current snr value
|
||||
uint16_t getSNRValue(void) { return snrbar->getValue();}
|
||||
|
||||
///return current snr value
|
||||
};
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user