mirror of
https://github.com/sparrowwallet/sparrow.git
synced 2025-11-05 11:56:37 +00:00
select first matching webcam by name
This commit is contained in:
parent
cec7eac9ac
commit
49ab9e40e3
1 changed files with 2 additions and 0 deletions
|
|
@ -139,12 +139,14 @@ public class WebcamService extends ScheduledService<Image> {
|
|||
for(CaptureDevice webcam : availableDevices) {
|
||||
if(webcam.getName().equals(device.getName())) {
|
||||
selectedDevice = webcam;
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else if(Config.get().getWebcamDevice() != null) {
|
||||
for(CaptureDevice webcam : availableDevices) {
|
||||
if(webcam.getName().equals(Config.get().getWebcamDevice())) {
|
||||
selectedDevice = webcam;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue