mirror of
				https://gitlab.freedesktop.org/pipewire/pipewire.git
				synced 2025-11-03 09:01:54 -05:00 
			
		
		
		
	pulse-server: fill in active port for monitors
The monitor sources also list the port of the sink and so the active port needs to be collected as well so it doesn't fall back to the first port (which might not be available).
This commit is contained in:
		
							parent
							
								
									bd87902da6
								
							
						
					
					
						commit
						fffda6b6d1
					
				
					 1 changed files with 2 additions and 2 deletions
				
			
		| 
						 | 
					@ -234,7 +234,7 @@ static void collect_device_info(struct pw_manager_object *device, struct pw_mana
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	struct pw_manager_param *p;
 | 
						struct pw_manager_param *p;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (card && !monitor) {
 | 
						if (card) {
 | 
				
			||||||
		spa_list_for_each(p, &card->param_list, link) {
 | 
							spa_list_for_each(p, &card->param_list, link) {
 | 
				
			||||||
			uint32_t index, dev;
 | 
								uint32_t index, dev;
 | 
				
			||||||
			struct spa_pod *props;
 | 
								struct spa_pod *props;
 | 
				
			||||||
| 
						 | 
					@ -251,7 +251,7 @@ static void collect_device_info(struct pw_manager_object *device, struct pw_mana
 | 
				
			||||||
			if (dev != dev_info->device)
 | 
								if (dev != dev_info->device)
 | 
				
			||||||
				continue;
 | 
									continue;
 | 
				
			||||||
			dev_info->active_port = index;
 | 
								dev_info->active_port = index;
 | 
				
			||||||
			if (props) {
 | 
								if (props && !monitor) {
 | 
				
			||||||
				volume_parse_param(props, &dev_info->volume_info, monitor);
 | 
									volume_parse_param(props, &dev_info->volume_info, monitor);
 | 
				
			||||||
				dev_info->have_volume = true;
 | 
									dev_info->have_volume = true;
 | 
				
			||||||
			}
 | 
								}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue