branch merge
authorEdouard Tisserant
Thu, 05 Apr 2012 04:42:01 +0200
changeset 714 f8ee6fd01f7c
parent 713 37dc330e96a2 (current diff)
parent 712 5a036ae4d6aa (diff)
child 715 135566ab0807
branch merge
Beremiz.py
--- a/Beremiz.py	Thu Apr 05 04:41:22 2012 +0200
+++ b/Beremiz.py	Thu Apr 05 04:42:01 2012 +0200
@@ -1634,10 +1634,11 @@
             self.Config.Write("lastopenedfolder", os.path.dirname(projectpath))
             self.Config.Flush()
             self.ResetView()
-            self.PluginRoot = PluginsRoot(self, self.Log)
-            self.Controler = self.PluginRoot
-            result = self.PluginRoot.NewProject(projectpath)
+            plugin_root = PluginsRoot(self, self.Log)
+            result = plugin_root.NewProject(projectpath)
             if not result:
+                self.PluginRoot = plugin_root
+                self.Controler = self.PluginRoot
                 self.RefreshConfigRecentProjects(projectpath)
                 if self.EnableDebug:
                     self.DebugVariablePanel.SetDataProducer(self.PluginRoot)