mirror of
https://github.com/home-assistant/core.git
synced 2025-07-16 17:57:11 +00:00
Always return rgb color of bulbs (#7743)
This commit is contained in:
parent
7055fddfb4
commit
b5f20c9b64
@ -19,8 +19,6 @@ DEPENDENCIES = ['wink']
|
|||||||
|
|
||||||
SUPPORT_WINK = SUPPORT_BRIGHTNESS | SUPPORT_COLOR_TEMP | SUPPORT_RGB_COLOR
|
SUPPORT_WINK = SUPPORT_BRIGHTNESS | SUPPORT_COLOR_TEMP | SUPPORT_RGB_COLOR
|
||||||
|
|
||||||
RGB_MODES = ['hsb', 'rgb']
|
|
||||||
|
|
||||||
|
|
||||||
def setup_platform(hass, config, add_devices, discovery_info=None):
|
def setup_platform(hass, config, add_devices, discovery_info=None):
|
||||||
"""Set up the Wink lights."""
|
"""Set up the Wink lights."""
|
||||||
@ -62,8 +60,6 @@ class WinkLight(WinkDevice, Light):
|
|||||||
"""Define current bulb color in RGB."""
|
"""Define current bulb color in RGB."""
|
||||||
if not self.wink.supports_hue_saturation():
|
if not self.wink.supports_hue_saturation():
|
||||||
return None
|
return None
|
||||||
elif self.wink.color_model() not in RGB_MODES:
|
|
||||||
return False
|
|
||||||
else:
|
else:
|
||||||
hue = self.wink.color_hue()
|
hue = self.wink.color_hue()
|
||||||
saturation = self.wink.color_saturation()
|
saturation = self.wink.color_saturation()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user