-
Notifications
You must be signed in to change notification settings - Fork 2
Description
Identifying media players by arbitrary properties (#17 ) is more complicated than it needs to be.
For SMTC there is only the AppUserModelId. On Mac there is only the bundle identifier (or parent application bundle identifier). On Linux there is only the MPRIS service name and the "Identity" property. On the web there's the domain name.
Instead of allowing any property to be matched, it's sufficient to assign labels to specific properties and use them or a combination of them:
sources:
lin_mpris:
- tidal-hifi # "service" by default
- service: tidal-hifi # same as previous line
- service: chromium
identity: tidal-hifi
- identity: whateverFor Linux, "service" must always be present. "identity" should be matched against org.mpris.MediaPlayer2.DesktopEntry. Additionally, "desktop_entry" should also be added to match against org.mpris.MediaPlayer2.DesktopEntry, if the need ever arises. That could theoretically be matched on its own then too (e.g. with Strawberry the desktop entry contains org.strawberrymusicplayer.strawberry).
For completeness:
sources:
win_smtc:
- foo.exe
- app_user_model_id: foo.exe
mac_bundle:
- app.foo
- bundle_identifier: app.foo
lin_mpris:
- foo
- service: foo
- service: chromium
identity: Foo
- service: chromium
desktop_entry: app.foo.desktop
web_domain:
- foo.com
- domain: foo.comMatching an empty string should be allowed with secondary properties ("identity" and "desktop_entry"). In that case the property must be actually empty.