mirror of
https://github.com/home-assistant/core.git
synced 2025-07-17 18:27:09 +00:00
Remove unnecessary should poll from media player classes (#41220)
This commit is contained in:
parent
b8ed9fb4c0
commit
228e167b03
@ -476,11 +476,6 @@ class ADBDevice(MediaPlayerEntity):
|
|||||||
"""Return the device name."""
|
"""Return the device name."""
|
||||||
return self._name
|
return self._name
|
||||||
|
|
||||||
@property
|
|
||||||
def should_poll(self):
|
|
||||||
"""Device should be polled."""
|
|
||||||
return True
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def source(self):
|
def source(self):
|
||||||
"""Return the current app."""
|
"""Return the current app."""
|
||||||
|
@ -126,11 +126,6 @@ class AFSAPIDevice(MediaPlayerEntity):
|
|||||||
"""
|
"""
|
||||||
return AFSAPI(self._device_url, self._password)
|
return AFSAPI(self._device_url, self._password)
|
||||||
|
|
||||||
@property
|
|
||||||
def should_poll(self):
|
|
||||||
"""Device should be polled."""
|
|
||||||
return True
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def name(self):
|
def name(self):
|
||||||
"""Return the device name."""
|
"""Return the device name."""
|
||||||
|
@ -187,11 +187,6 @@ class OpenhomeDevice(MediaPlayerEntity):
|
|||||||
"""Flag of features commands that are supported."""
|
"""Flag of features commands that are supported."""
|
||||||
return self._supported_features
|
return self._supported_features
|
||||||
|
|
||||||
@property
|
|
||||||
def should_poll(self):
|
|
||||||
"""Return the polling state."""
|
|
||||||
return True
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def unique_id(self):
|
def unique_id(self):
|
||||||
"""Return a unique ID."""
|
"""Return a unique ID."""
|
||||||
|
@ -88,11 +88,6 @@ class PandoraMediaPlayer(MediaPlayerEntity):
|
|||||||
self._media_duration = 0
|
self._media_duration = 0
|
||||||
self._pianobar = None
|
self._pianobar = None
|
||||||
|
|
||||||
@property
|
|
||||||
def should_poll(self):
|
|
||||||
"""Return the polling state."""
|
|
||||||
return True
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def name(self):
|
def name(self):
|
||||||
"""Return the name of the media player."""
|
"""Return the name of the media player."""
|
||||||
|
@ -137,11 +137,6 @@ class YamahaDevice(MediaPlayerEntity):
|
|||||||
return self.status
|
return self.status
|
||||||
return self.power
|
return self.power
|
||||||
|
|
||||||
@property
|
|
||||||
def should_poll(self):
|
|
||||||
"""Push an update after each command."""
|
|
||||||
return True
|
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def is_volume_muted(self):
|
def is_volume_muted(self):
|
||||||
"""Boolean if volume is currently muted."""
|
"""Boolean if volume is currently muted."""
|
||||||
|
Loading…
x
Reference in New Issue
Block a user