From 9b0dbf3fbe8a5010f7b070567122246e667c2fe5 Mon Sep 17 00:00:00 2001 From: ErnstEeldert Date: Sat, 3 Feb 2018 17:08:00 +0100 Subject: [PATCH] Adding xy_color attribute support to deconz lights (#12106) --- homeassistant/components/light/deconz.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/homeassistant/components/light/deconz.py b/homeassistant/components/light/deconz.py index 82df352e5af..529917c36e2 100644 --- a/homeassistant/components/light/deconz.py +++ b/homeassistant/components/light/deconz.py @@ -9,7 +9,7 @@ import asyncio from homeassistant.components.deconz import DOMAIN as DECONZ_DATA from homeassistant.components.light import ( ATTR_BRIGHTNESS, ATTR_COLOR_TEMP, ATTR_EFFECT, ATTR_FLASH, ATTR_RGB_COLOR, - ATTR_TRANSITION, EFFECT_COLORLOOP, FLASH_LONG, FLASH_SHORT, + ATTR_TRANSITION, ATTR_XY_COLOR, EFFECT_COLORLOOP, FLASH_LONG, FLASH_SHORT, SUPPORT_BRIGHTNESS, SUPPORT_COLOR_TEMP, SUPPORT_EFFECT, SUPPORT_FLASH, SUPPORT_RGB_COLOR, SUPPORT_TRANSITION, SUPPORT_XY_COLOR, Light) from homeassistant.core import callback @@ -134,6 +134,9 @@ class DeconzLight(Light): data['xy'] = xyb[0], xyb[1] data['bri'] = xyb[2] + if ATTR_XY_COLOR in kwargs: + data['xy'] = kwargs[ATTR_XY_COLOR] + if ATTR_BRIGHTNESS in kwargs: data['bri'] = kwargs[ATTR_BRIGHTNESS]