mirror of
https://github.com/esphome/esphome.git
synced 2025-10-31 23:21:54 +00:00
drop double copy
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
namespace esphome {
|
||||
namespace select {
|
||||
|
||||
void SelectTraits::set_options(std::initializer_list<std::string> options) { this->options_ = options; }
|
||||
void SelectTraits::set_options(const std::initializer_list<std::string> &options) { this->options_ = options; }
|
||||
|
||||
const FixedVector<std::string> &SelectTraits::get_options() const { return this->options_; }
|
||||
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace select {
|
||||
|
||||
class SelectTraits {
|
||||
public:
|
||||
void set_options(std::initializer_list<std::string> options);
|
||||
void set_options(const std::initializer_list<std::string> &options);
|
||||
const FixedVector<std::string> &get_options() const;
|
||||
/// Copy options from another SelectTraits (for copy_select, lvgl)
|
||||
void copy_options(const FixedVector<std::string> &other) { this->options_.copy_from(other); }
|
||||
|
||||
Reference in New Issue
Block a user