1
0
mirror of https://github.com/esphome/esphome.git synced 2025-10-28 21:53:48 +00:00

Revert nextion clang-tidy changes (#2566)

This commit is contained in:
Otto Winter
2021-10-20 20:31:13 +02:00
committed by GitHub
parent 64a45dc6a6
commit 15b5968418
13 changed files with 78 additions and 70 deletions

View File

@@ -18,7 +18,7 @@ void NextionTextSensor::process_text(const std::string &variable_name, const std
void NextionTextSensor::update() {
if (!this->nextion_->is_setup())
return;
this->nextion_->add_to_get_queue(shared_from_this());
this->nextion_->add_to_get_queue(this);
}
void NextionTextSensor::set_state(const std::string &state, bool publish, bool send_to_nextion) {
@@ -29,7 +29,7 @@ void NextionTextSensor::set_state(const std::string &state, bool publish, bool s
if (this->nextion_->is_sleeping() || !this->visible_) {
this->needs_to_send_update_ = true;
} else {
this->nextion_->add_no_result_to_queue_with_set(shared_from_this(), state);
this->nextion_->add_no_result_to_queue_with_set(this, state);
}
}

View File

@@ -8,10 +8,7 @@ namespace esphome {
namespace nextion {
class NextionTextSensor;
class NextionTextSensor : public NextionComponent,
public text_sensor::TextSensor,
public PollingComponent,
public std::enable_shared_from_this<NextionTextSensor> {
class NextionTextSensor : public NextionComponent, public text_sensor::TextSensor, public PollingComponent {
public:
NextionTextSensor(NextionBase *nextion) { this->nextion_ = nextion; }
void update() override;