CecTray: don't use lazy loading for the main controller, but pass the instance. bugzi...
[deb_libcec.git] / src / LibCecTray / controller / applications / ConfigureApplication.cs
index 2e5897709dca21958797e3aa5491bd0163e371d8..ad0682057b0c7b38bbd9cc01f015d96514b5dc55 100644 (file)
@@ -132,7 +132,7 @@ namespace LibCECTray.controller.applications
       }
       else if (_cecController != null)
       {
-        ApplicationController newController = new ApplicationController(_settings, tbUiName.Text, tbProcessName.Text, tbFilename.Text, tbWorkingDir.Text);
+        ApplicationController newController = new ApplicationController(_cecController, tbUiName.Text, tbProcessName.Text, tbFilename.Text, tbWorkingDir.Text);
         if (_cecController.RegisterApplication(newController))
           newController.Settings.Persist();
       }
@@ -145,8 +145,8 @@ namespace LibCECTray.controller.applications
       Dispose();
     }
 
-    private ApplicationController _controller;
-    private CECController _cecController;
-    private CECSettings _settings;
+    private readonly ApplicationController _controller;
+    private readonly CECController _cecController;
+    private readonly CECSettings _settings;
   }
 }