Wim Taymans
c0ed88f2f9
media-session: always try to activate the saved profile
...
When the current profile is not the saved profile, check if the
saved profile is available again and try to activate it.
2021-01-28 16:56:27 +01:00
Wim Taymans
f03deb5324
media-session: try to avoid switching away from hdmi
...
When HDMI goes to sleep the profile becomes unavailable. Avoid
switching to Off in that case.
2021-01-28 15:41:14 +01:00
Wim Taymans
fc08c79dad
media-session: start timeout only when something changed
2021-01-28 14:36:29 +01:00
Wim Taymans
072d3a191c
media-session: keep track of all active routes
...
Keep track of active profile in default-routes so that we can restore
the prefered routes later.
Keep track of all active routes in an array. There can be more than
one active route per direction.
New routes will get their volume restored. Route changes will be saved.
2021-01-28 14:28:46 +01:00
Wim Taymans
b8bac95dad
media-session: add info logging to profile restore logic
2021-01-28 11:43:17 +01:00
Wim Taymans
0be851739f
improve config parsing
...
Use get_string to get object keys in a more generic way.
2021-01-27 15:36:32 +01:00
Wim Taymans
585f533d27
media-session: move profile selection to media-session
...
Disable automatic profile selection in the acp device
Implement selection of profiles in the default-profile module
2021-01-27 13:48:10 +01:00
Wim Taymans
cf35e52586
media-session: use the right define for the bitmask
2021-01-27 13:48:10 +01:00
Wim Taymans
c95bd1c3d4
media-session: avoid restoring an unavailable profile
2021-01-25 16:00:20 +01:00
Wim Taymans
98a3527685
media-session: init current_profile to invalid
...
So that we can detect a switch..
2021-01-25 15:53:54 +01:00
Wim Taymans
39f082fc86
default-profile: don't try to restore bluetooth profiles
2021-01-25 13:17:22 +01:00
Wim Taymans
62cdec8448
spa: move json parser to utils
...
Add unit test
Add escape function
2020-11-28 15:34:01 +01:00
Wim Taymans
7ca8491be3
media-session: store values as json
...
Save settings as jason and use a small json compatible tokenizer to
load settings instead of our own less flexible format.
Save settings with a prefix and filter out entries without prefix
Listen for changes in restore.stream metadata and update properties.
2020-11-22 10:00:58 +01:00
Wim Taymans
f9a5053c73
media-session: improve cleanup in some modules
2020-08-17 17:50:15 +02:00
Wim Taymans
e544f82004
Revert "default-profile: keep a restore and save list"
...
This reverts commit de71618b99 .
Doesn't work when the device is removed and added again.
2020-08-17 16:04:22 +02:00
Wim Taymans
de71618b99
default-profile: keep a restore and save list
...
Load the settings into the restore list, when we see a device and it's
in the restore list, restore the profile and remove from restore list.
All updates to profiles go into the save list and it is then saved.
2020-08-17 11:48:52 +02:00
Wim Taymans
31a3fab554
media-session: use name from Profile param
2020-08-17 11:15:44 +02:00
Wim Taymans
4ad6c627a0
media-session: add module to restore card profile
...
Save card profiles to file and restore.
2020-08-13 17:01:47 +02:00