diff main/MainWindow.cpp @ 2240:ca0ee1fe88c7 single-point

Support OSC script even with no OSC port
author Chris Cannam
date Thu, 28 Mar 2019 13:38:24 +0000
parents a4dde0f408e4
children e9c77a4c865e
line wrap: on
line diff
--- a/main/MainWindow.cpp	Thu Mar 28 11:58:58 2019 +0000
+++ b/main/MainWindow.cpp	Thu Mar 28 13:38:24 2019 +0000
@@ -332,11 +332,6 @@
     NetworkPermissionTester tester(withOSCSupport);
     bool networkPermission = tester.havePermission();
     if (networkPermission) {
-        if (withOSCSupport) {
-            SVDEBUG << "MainWindow: Creating OSC queue" << endl;
-            startOSCQueue();
-        }
-
         SVDEBUG << "MainWindow: Starting transform population thread" << endl;
         TransformFactory::getInstance()->startPopulationThread();
 
@@ -354,6 +349,16 @@
         m_versionTester = nullptr;
     }
 
+    if (withOSCSupport && networkPermission) {
+        SVDEBUG << "MainWindow: Creating OSC queue with network port"
+                << endl;
+        startOSCQueue(true);
+    } else {
+        SVDEBUG << "MainWindow: Creating internal-only OSC queue without port"
+                << endl;
+        startOSCQueue(false);
+    }
+    
 /*
     QTimer::singleShot(500, this, SLOT(betaReleaseWarning()));
 */