mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Better Bluetooth device support on Mac
We now show the correct device name for Bluetooth connected dive computers in the drop down menu in the Download dialog. This also updates the corresponding chapter in user manual. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
6855be0f1c
commit
e5f2f3e65f
2 changed files with 9 additions and 7 deletions
3
macos.c
3
macos.c
|
@ -87,7 +87,8 @@ int subsurface_fill_device_list(GtkListStore *store)
|
|||
|
||||
dev = g_dir_open("/dev", 0, NULL);
|
||||
while (dev && (name = g_dir_read_name(dev)) != NULL) {
|
||||
if (strstr(name, "usbserial")) {
|
||||
if (strstr(name, "usbserial") ||
|
||||
(strstr(name, "SerialPort") && strstr(name, "cu"))) {
|
||||
int len = strlen(name) + 6;
|
||||
char *devicename = malloc(len);
|
||||
snprintf(devicename, len, "/dev/%s", name);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue