Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions homeassistant/components/blackbird/const.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
"""Constants for the Monoprice Blackbird Matrix Switch component."""
DOMAIN = "blackbird"
SERVICE_SETALLZONES = "set_all_zones"
3 changes: 1 addition & 2 deletions homeassistant/components/blackbird/media_player.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@

from homeassistant.components.media_player import PLATFORM_SCHEMA, MediaPlayerDevice
from homeassistant.components.media_player.const import (
DOMAIN,
SUPPORT_SELECT_SOURCE,
SUPPORT_TURN_OFF,
SUPPORT_TURN_ON,
Expand All @@ -23,6 +22,7 @@
STATE_ON,
)
import homeassistant.helpers.config_validation as cv
from .const import DOMAIN, SERVICE_SETALLZONES

_LOGGER = logging.getLogger(__name__)

Expand All @@ -39,7 +39,6 @@

DATA_BLACKBIRD = "blackbird"

SERVICE_SETALLZONES = "blackbird_set_all_zones"
ATTR_SOURCE = "source"

BLACKBIRD_SETALLZONES_SCHEMA = MEDIA_PLAYER_SCHEMA.extend(
Expand Down
10 changes: 10 additions & 0 deletions homeassistant/components/blackbird/services.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
set_all_zones:
description: Set all Blackbird zones to a single source.
fields:
entity_id:
description: Name of any blackbird zone.
example: 'media_player.zone_1'
source:
description: Name of source to switch to.
example: 'Source 1'

10 changes: 0 additions & 10 deletions homeassistant/components/media_player/services.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -303,16 +303,6 @@ songpal_set_sound_setting:
description: Value to set.
example: 'on'

blackbird_set_all_zones:
description: Set all Blackbird zones to a single source.
fields:
entity_id:
description: Name of any blackbird zone.
example: 'media_player.zone_1'
source:
description: Name of source to switch to.
example: 'Source 1'

epson_select_cmode:
description: Select Color mode of Epson projector
fields:
Expand Down
3 changes: 1 addition & 2 deletions tests/components/blackbird/test_media_player.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

from collections import defaultdict
from homeassistant.components.media_player.const import (
DOMAIN,
SUPPORT_TURN_ON,
SUPPORT_TURN_OFF,
SUPPORT_SELECT_SOURCE,
Expand All @@ -16,9 +15,9 @@
from homeassistant.components.blackbird.media_player import (
DATA_BLACKBIRD,
PLATFORM_SCHEMA,
SERVICE_SETALLZONES,
setup_platform,
)
from homeassistant.components.blackbird.const import DOMAIN, SERVICE_SETALLZONES
import pytest


Expand Down