mirror of
https://github.com/Threnklyn/esphome-dev.git
synced 2026-05-30 01:38:27 +02:00
Fix validation of addressable light IDs (#2588)
This commit is contained in:
committed by
Otto winter
parent
68cbe58d00
commit
bbcd523967
@@ -22,6 +22,12 @@ using ESPColor ESPDEPRECATED("esphome::light::ESPColor is deprecated, use esphom
|
||||
/// Convert the color information from a `LightColorValues` object to a `Color` object (does not apply brightness).
|
||||
Color color_from_light_color_values(LightColorValues val);
|
||||
|
||||
/// Use a custom state class for addressable lights, to allow type system to discriminate between addressable and
|
||||
/// non-addressable lights.
|
||||
class AddressableLightState : public LightState {
|
||||
using LightState::LightState;
|
||||
};
|
||||
|
||||
class AddressableLight : public LightOutput, public Component {
|
||||
public:
|
||||
virtual int32_t size() const = 0;
|
||||
|
||||
Reference in New Issue
Block a user