mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-28 07:51:19 +02:00
CComponentsFooter: Function setButtonLabels() change parameter
Performance: parameter 'v_content' should be passed by reference
This commit is contained in:
@@ -221,7 +221,7 @@ void CComponentsFooter::setButtonLabels(const struct button_label * const conten
|
|||||||
setButtonLabels(buttons, label_count, chain_width, label_width);
|
setButtonLabels(buttons, label_count, chain_width, label_width);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CComponentsFooter::setButtonLabels(const vector<button_label_l>v_content, const int& chain_width, const int& label_width)
|
void CComponentsFooter::setButtonLabels(const vector<button_label_l> &v_content, const int& chain_width, const int& label_width)
|
||||||
{
|
{
|
||||||
size_t label_count = v_content.size();
|
size_t label_count = v_content.size();
|
||||||
button_label_l buttons[label_count];
|
button_label_l buttons[label_count];
|
||||||
@@ -237,7 +237,7 @@ void CComponentsFooter::setButtonLabels(const vector<button_label_l>v_content, c
|
|||||||
setButtonLabels(buttons, label_count, chain_width, label_width);
|
setButtonLabels(buttons, label_count, chain_width, label_width);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CComponentsFooter::setButtonLabels(const vector<button_label_s>v_content, const int& chain_width, const int& label_width)
|
void CComponentsFooter::setButtonLabels(const vector<button_label_s> &v_content, const int& chain_width, const int& label_width)
|
||||||
{
|
{
|
||||||
size_t label_count = v_content.size();
|
size_t label_count = v_content.size();
|
||||||
button_label_s buttons[label_count];
|
button_label_s buttons[label_count];
|
||||||
|
@@ -93,9 +93,9 @@ class CComponentsFooter : public CComponentsHeader
|
|||||||
///add button labels with locale label type as content, count as size_t, chain_width as int, label width as int
|
///add button labels with locale label type as content, count as size_t, chain_width as int, label width as int
|
||||||
void setButtonLabels(const struct button_label_l * const content, const size_t& label_count, const int& chain_width = 0, const int& label_width = 0);
|
void setButtonLabels(const struct button_label_l * const content, const size_t& label_count, const int& chain_width = 0, const int& label_width = 0);
|
||||||
///add button labels with locale label type as content, parameter 1 as vector, chain_width as int, label width as int
|
///add button labels with locale label type as content, parameter 1 as vector, chain_width as int, label width as int
|
||||||
void setButtonLabels(const std::vector<button_label_l>v_content, const int& chain_width, const int& label_width);
|
void setButtonLabels(const std::vector<button_label_l> &v_content, const int& chain_width, const int& label_width);
|
||||||
///add button labels with string label type as content, parameter 1 as vector, chain_width as int, label width as int
|
///add button labels with string label type as content, parameter 1 as vector, chain_width as int, label width as int
|
||||||
void setButtonLabels(const std::vector<button_label_s>v_content, const int& chain_width, const int& label_width);
|
void setButtonLabels(const std::vector<button_label_s> &v_content, const int& chain_width, const int& label_width);
|
||||||
|
|
||||||
///enable/disable button frame in icon color, predefined for red, green, yellow and blue
|
///enable/disable button frame in icon color, predefined for red, green, yellow and blue
|
||||||
inline void enableButtonFrameColor(bool enable = true){btn_auto_frame_col = enable;}
|
inline void enableButtonFrameColor(bool enable = true){btn_auto_frame_col = enable;}
|
||||||
|
Reference in New Issue
Block a user