Beremiz.py
changeset 388 9d5b3d63563d
parent 383 9ae15ab058f3
child 395 433fd448dd31
--- a/Beremiz.py	Thu Sep 03 11:28:46 2009 +0200
+++ b/Beremiz.py	Thu Sep 03 12:09:39 2009 +0200
@@ -1252,6 +1252,9 @@
             dialog.Destroy()
             config.Write("lastopenedfolder", os.path.dirname(projectpath))
             config.Flush()
+            self.PluginInfos = {}
+            if self.PluginRoot is not None:
+                self.PluginRoot.CloseProject()
             self.PluginRoot = PluginsRoot(self, self.Log)
             res = self.PluginRoot.NewProject(projectpath)
             if not res :
@@ -1275,6 +1278,9 @@
             if os.path.isdir(projectpath):
                 config.Write("lastopenedfolder", os.path.dirname(projectpath))
                 config.Flush()
+                self.PluginInfos = {}
+                if self.PluginRoot is not None:
+                    self.PluginRoot.CloseProject()
                 self.PluginRoot = PluginsRoot(self, self.Log)
                 result = self.PluginRoot.LoadProject(projectpath)
                 if not result: