From ebcd765d6e53b3359fa5a52b64f799b6ca05c75a Mon Sep 17 00:00:00 2001 From: Michael Smith Date: Wed, 11 Sep 2024 21:37:04 -0400 Subject: [PATCH] fix: switch base class to plain component --- esphome/components/pwrman_charger/pwrman_charger.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/esphome/components/pwrman_charger/pwrman_charger.h b/esphome/components/pwrman_charger/pwrman_charger.h index 2e96721..edbf572 100644 --- a/esphome/components/pwrman_charger/pwrman_charger.h +++ b/esphome/components/pwrman_charger/pwrman_charger.h @@ -63,7 +63,7 @@ static const uint8_t PWRMAN_CHARGER_REGISTER_OTP_SW_REV = 0x23; /// This hot-swappable module can be remotely managed and monitored via /// I2C and is capable of up to 100W charging. This class is for the /// central configuration. -class PwrmanCharger : public i2c::I2CDevice, public PollingComponent { +class PwrmanCharger : public i2c::I2CDevice, public Component { #ifdef USE_SWITCH protected: switch_::Switch *enable_12v_switch_{nullptr}; @@ -86,12 +86,12 @@ class PwrmanCharger : public i2c::I2CDevice, public PollingComponent { /** Sets the button for sending a SRC_CAP message to the sink. */ void set_src_cap_button(button::Button *button) { this->src_cap_button_ = button; } + /** Used by ESPHome framework. */ + float get_setup_priority() const override; /** Used by ESPHome framework. */ void setup() override; /** Used by ESPHome framework. */ void dump_config() override; - /** Used by ESPHome framework. */ - float get_setup_priority() const override; protected: i2c::ErrorCode last_error_;