Media player - Buttons

- Added code to buttons on media_player page.
- Clean-up:
  - Moved wake-up select from Blueprint to ESPHome component
  - Removed `switch.xxxxx_confirmation_message`
This commit is contained in:
Edward Firmo
2023-09-10 22:37:36 +02:00
parent 796968122b
commit 591c7aa69b
11 changed files with 445 additions and 168 deletions

View File

@@ -93,7 +93,7 @@ Text vol_text
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 35%
Text :
Max. Text Size : 10
Text bt_vol_down
@@ -106,6 +106,16 @@ Text bt_vol_down
Text :
Max. Text Size : 3
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"event\": \"short_click\", \"component\": \"bt_vol_down\", \"entity\": \""+entity.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_vol_up
Attributes
ID : 9
@@ -116,6 +126,16 @@ Text bt_vol_up
Text :
Max. Text Size : 3
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"event\": \"short_click\", \"component\": \"bt_vol_up\", \"entity\": \""+entity.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_mute
Attributes
ID : 10
@@ -126,6 +146,16 @@ Text bt_mute
Text :
Max. Text Size : 3
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"event\": \"short_click\", \"component\": \"bt_mute\", \"entity\": \""+entity.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text time_current
Attributes
ID : 12
@@ -133,7 +163,7 @@ Text time_current
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 2:15
Text :
Max. Text Size : 10
Text time_total
@@ -143,7 +173,7 @@ Text time_total
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : 7:29
Text :
Max. Text Size : 10
Text track
@@ -153,7 +183,7 @@ Text track
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Music name
Text :
Max. Text Size : 50
Text artist
@@ -163,7 +193,7 @@ Text artist
Dragging : 0
Send Component ID : disabled
Associated Keyboard: none
Text : Artist name
Text :
Max. Text Size : 50
Text bt_prev
@@ -176,6 +206,16 @@ Text bt_prev
Text :
Max. Text Size : 10
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"event\": \"short_click\", \"component\": \"bt_prev\", \"entity\": \""+entity.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_play_pause
Attributes
ID : 17
@@ -186,6 +226,16 @@ Text bt_play_pause
Text :
Max. Text Size : 10
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"event\": \"short_click\", \"component\": \"bt_play_pause\", \"entity\": \""+entity.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_stop
Attributes
ID : 18
@@ -196,6 +246,16 @@ Text bt_stop
Text :
Max. Text Size : 10
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"event\": \"short_click\", \"component\": \"bt_stop\", \"entity\": \""+entity.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_next
Attributes
ID : 19
@@ -206,6 +266,16 @@ Text bt_next
Text :
Max. Text Size : 10
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"event\": \"short_click\", \"component\": \"bt_next\", \"entity\": \""+entity.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Text bt_on_off
Attributes
ID : 20
@@ -216,13 +286,23 @@ Text bt_on_off
Text :
Max. Text Size : 10
Events
Touch Release Event
lastclick.txt="{\"page\": \"media_player\", \"event\": \"short_click\", \"component\": \"bt_on_off\", \"entity\": \""+entity.txt+"\"}"
printh 92
prints "localevent",0
printh 00
prints lastclick.txt,0
printh 00
printh FF FF FF
Progress Bar time_progress
Attributes
ID : 11
Scope : local
Dragging : 0
Send Component ID: disabled
Value : 34
Value : 0
Slider vol_slider
Attributes
@@ -230,7 +310,7 @@ Slider vol_slider
Scope : local
Dragging : 0
Send Component ID: disabled
Position : 35
Position : 0
Upper range limit: 100
Lower range limit: 0