Browse Source

Don't show the dialog with no capabilities

Clara Hobbs 6 years ago
parent
commit
83493dce78
1 changed files with 4 additions and 0 deletions
  1. 4
    0
      pd-buddy-gtk.py

+ 4
- 0
pd-buddy-gtk.py View File

@@ -434,6 +434,10 @@ class Handler:
434 434
         with pdbuddy.Sink(self.serial_port) as pdbs:
435 435
             caps = pdbs.get_source_cap()
436 436
 
437
+        if not caps:
438
+            # If there are no capabilities, don't show a dialog
439
+            return
440
+
437 441
         # Create the dialog
438 442
         window = self.builder.get_object("pdb-window")
439 443
         dialog_builder = Gtk.Builder.new_from_file("data/src-cap-dialog.ui")

Loading…
Cancel
Save