Use new enums in deconz (#61343)

Co-authored-by: epenet <epenet@users.noreply.github.com>
This commit is contained in:
epenet 2021-12-09 13:23:01 +01:00 committed by GitHub
parent 2e99fbc1f3
commit fa38a2d0bf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 34 additions and 47 deletions

View file

@ -10,8 +10,6 @@ from pydeconz.light import Cover
from homeassistant.components.cover import (
ATTR_POSITION,
ATTR_TILT_POSITION,
DEVICE_CLASS_DAMPER,
DEVICE_CLASS_SHADE,
DOMAIN,
SUPPORT_CLOSE,
SUPPORT_CLOSE_TILT,
@ -21,6 +19,7 @@ from homeassistant.components.cover import (
SUPPORT_SET_TILT_POSITION,
SUPPORT_STOP,
SUPPORT_STOP_TILT,
CoverDeviceClass,
CoverEntity,
)
from homeassistant.config_entries import ConfigEntry
@ -32,9 +31,9 @@ from .deconz_device import DeconzDevice
from .gateway import DeconzGateway, get_gateway_from_config_entry
DEVICE_CLASS = {
"Level controllable output": DEVICE_CLASS_DAMPER,
"Window covering controller": DEVICE_CLASS_SHADE,
"Window covering device": DEVICE_CLASS_SHADE,
"Level controllable output": CoverDeviceClass.DAMPER,
"Window covering controller": CoverDeviceClass.SHADE,
"Window covering device": CoverDeviceClass.SHADE,
}