3338ebd4c161f3e02269b94cf79d2b53bc70d6f9,homeassistant/components/switch/flux.py,,set_lights_xy,#Any#Any#Any#Any#Any#Any#,70

Before Change


    Set color of array of lights.
    for light in lights:
        if is_on(hass, light):
            hass.services.call(
                LIGHT_DOMAIN, SERVICE_TURN_ON, {
                    ATTR_XY_COLOR: [x_val, y_val],
                    ATTR_BRIGHTNESS: brightness,
                    ATTR_TRANSITION: transition,
                    ATTR_WHITE_VALUE: brightness,
                    ATTR_ENTITY_ID: light})


def set_lights_temp(hass, lights, mired, brightness, transition):
    Set color of array of lights.

After Change


    Set color of array of lights.
    for light in lights:
        if is_on(hass, light):
            service_data = {ATTR_ENTITY_ID: light}
            if x_val is not None and y_val is not None:
                service_data[ATTR_XY_COLOR] = [x_val, y_val]
            if brightness is not None:
                service_data[ATTR_BRIGHTNESS] = brightness
                service_data[ATTR_WHITE_VALUE] = brightness
            if transition is not None:
                service_data[ATTR_TRANSITION] = transition
            hass.services.call(
                LIGHT_DOMAIN, SERVICE_TURN_ON, service_data)


def set_lights_temp(hass, lights, mired, brightness, transition):
    Set color of array of lights.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 24

Instances


Project Name: home-assistant/home-assistant
Commit Name: 3338ebd4c161f3e02269b94cf79d2b53bc70d6f9
Time: 2018-10-07
Author: 30130371+cdce8p@users.noreply.github.com
File Name: homeassistant/components/switch/flux.py
Class Name:
Method Name: set_lights_xy


Project Name: home-assistant/home-assistant
Commit Name: 5d6562a73f00409668deaa8fd325f5bda7e7da6b
Time: 2018-10-06
Author: 30130371+cdce8p@users.noreply.github.com
File Name: homeassistant/components/switch/flux.py
Class Name:
Method Name: set_lights_temp


Project Name: home-assistant/home-assistant
Commit Name: 3338ebd4c161f3e02269b94cf79d2b53bc70d6f9
Time: 2018-10-07
Author: 30130371+cdce8p@users.noreply.github.com
File Name: homeassistant/components/switch/flux.py
Class Name:
Method Name: set_lights_xy


Project Name: home-assistant/home-assistant
Commit Name: 3338ebd4c161f3e02269b94cf79d2b53bc70d6f9
Time: 2018-10-07
Author: 30130371+cdce8p@users.noreply.github.com
File Name: homeassistant/components/switch/flux.py
Class Name:
Method Name: set_lights_temp