From 2f6ab2813ecd38e188f2a8d0726ff4a03b6a5241 Mon Sep 17 00:00:00 2001 From: Franck Nijhof Date: Sat, 2 Apr 2022 10:50:38 +0200 Subject: [PATCH 1/2] Add EntityFeature enum to Media Player --- docs/core/entity/media-player.md | 41 +++++++++++++++++--------------- 1 file changed, 22 insertions(+), 19 deletions(-) diff --git a/docs/core/entity/media-player.md b/docs/core/entity/media-player.md index 82b2ed22cf8..089bbc58afe 100644 --- a/docs/core/entity/media-player.md +++ b/docs/core/entity/media-player.md @@ -28,25 +28,28 @@ Properties should always only return information from memory and not do I/O (lik ## Supported Features -| Constant | Description -| -------- | ----------- -| `SUPPORT_CLEAR_PLAYLIST` | Entity allows clearing the active playlist. -| `SUPPORT_GROUPING` | Entity can be grouped with other players for synchronous playback. -| `SUPPORT_NEXT_TRACK` | Entity allows skipping to the next media track. -| `SUPPORT_PAUSE` | Entity allows pausing the playback of media. -| `SUPPORT_PLAY` | Entity allows playing/resuming playback of media. -| `SUPPORT_PLAY_MEDIA` | Entity allows playing media sources. -| `SUPPORT_PREVIOUS_TRACK` | Entity allows returning back to a previous media track. -| `SUPPORT_SEEK` | Entity allows seeking position during playback of media. -| `SUPPORT_SELECT_SOURCE` | Entity allows selecting a source/input. -| `SUPPORT_SELECT_SOUND_MODE` | Entity allows selecting a sound mode. -| `SUPPORT_SHUFFLE_SET` | Entity allows shuffling the active playlist. -| `SUPPORT_STOP` | Entity allows stopping the playback of media. -| `SUPPORT_TURN_OFF` | Entity is able to be turned off. -| `SUPPORT_TURN_ON` | Entity is able to be turned on. -| `SUPPORT_VOLUME_MUTE` | Entity volume can be muted. -| `SUPPORT_VOLUME_SET` | Entity volume can be set to specific levels. -| `SUPPORT_VOLUME_STEP` | Entity volume can be adjusted up and down. +Supported features are defined by using values in the `MediaPlayerFeature` enum +and are combined using the bitwise or (`|`) operator. + +| Value | Description | +| ------------------- | ------------------------------------------------------------------ | +| `CLEAR_PLAYLIST` | Entity allows clearing the active playlist. | +| `GROUPING` | Entity can be grouped with other players for synchronous playback. | +| `NEXT_TRACK` | Entity allows skipping to the next media track. | +| `PAUSE` | Entity allows pausing the playback of media. | +| `PLAY` | Entity allows playing/resuming playback of media. | +| `PLAY_MEDIA` | Entity allows playing media sources. | +| `PREVIOUS_TRACK` | Entity allows returning back to a previous media track. | +| `SEEK` | Entity allows seeking position during playback of media. | +| `SELECT_SOURCE` | Entity allows selecting a source/input. | +| `SELECT_SOUND_MODE` | Entity allows selecting a sound mode. | +| `SHUFFLE_SET` | Entity allows shuffling the active playlist. | +| `STOP` | Entity allows stopping the playback of media. | +| `TURN_OFF` | Entity is able to be turned off. | +| `TURN_ON` | Entity is able to be turned on. | +| `VOLUME_MUTE` | Entity volume can be muted. | +| `VOLUME_SET` | Entity volume can be set to specific levels. | +| `VOLUME_STEP` | Entity volume can be adjusted up and down. | ## Methods From 28c6a27f86e0452ef952b9459c6e1d7f2d99e873 Mon Sep 17 00:00:00 2001 From: Franck Nijhof Date: Sat, 2 Apr 2022 11:07:50 +0200 Subject: [PATCH 2/2] Typo --- docs/core/entity/media-player.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/core/entity/media-player.md b/docs/core/entity/media-player.md index 089bbc58afe..b29fa0c3604 100644 --- a/docs/core/entity/media-player.md +++ b/docs/core/entity/media-player.md @@ -28,7 +28,7 @@ Properties should always only return information from memory and not do I/O (lik ## Supported Features -Supported features are defined by using values in the `MediaPlayerFeature` enum +Supported features are defined by using values in the `MediaPlayerEntityFeature` enum and are combined using the bitwise or (`|`) operator. | Value | Description |