mirror of
https://github.com/esphome/esphome.git
synced 2025-04-07 03:10:27 +01:00
Co-authored-by: Jesse Hills <3060199+jesserockz@users.noreply.github.com> Co-authored-by: Spencer Yan <spencer@spenyan.com>
16 lines
363 B
C++
16 lines
363 B
C++
#include "height_threshold_select.h"
|
|
|
|
namespace esphome {
|
|
namespace seeed_mr60fda2 {
|
|
|
|
void HeightThresholdSelect::control(const std::string &value) {
|
|
this->publish_state(value);
|
|
auto index = this->index_of(value);
|
|
if (index.has_value()) {
|
|
this->parent_->set_height_threshold(index.value());
|
|
}
|
|
}
|
|
|
|
} // namespace seeed_mr60fda2
|
|
} // namespace esphome
|