Use enums in samsung_tv (#62047)
parent
fa522fc504
commit
395fa6d15f
|
@ -8,7 +8,10 @@ from typing import Any
|
|||
import voluptuous as vol
|
||||
from wakeonlan import send_magic_packet
|
||||
|
||||
from homeassistant.components.media_player import DEVICE_CLASS_TV, MediaPlayerEntity
|
||||
from homeassistant.components.media_player import (
|
||||
MediaPlayerDeviceClass,
|
||||
MediaPlayerEntity,
|
||||
)
|
||||
from homeassistant.components.media_player.const import (
|
||||
MEDIA_TYPE_CHANNEL,
|
||||
SUPPORT_NEXT_TRACK,
|
||||
|
@ -104,7 +107,7 @@ class SamsungTVDevice(MediaPlayerEntity):
|
|||
self._attr_state: str | None = None
|
||||
self._attr_unique_id = config_entry.unique_id
|
||||
self._attr_is_volume_muted: bool = False
|
||||
self._attr_device_class = DEVICE_CLASS_TV
|
||||
self._attr_device_class = MediaPlayerDeviceClass.TV
|
||||
self._attr_source_list = list(SOURCES)
|
||||
|
||||
if self._on_script or self._mac:
|
||||
|
|
Loading…
Reference in New Issue