merge
authorAndrey Skvortsov <andrej.skvortzov@gmail.com>
Tue, 17 Jan 2017 16:34:24 +0300
changeset 1638 3f86e9768f14
parent 1637 6f4624687b89 (current diff)
parent 1634 299a1dde6baa (diff)
child 1639 1953c268a194
merge
--- a/Beremiz.py	Tue Jan 17 13:30:38 2017 +0300
+++ b/Beremiz.py	Tue Jan 17 16:34:24 2017 +0300
@@ -522,7 +522,7 @@
         if projectOpen is not None and os.path.isdir(projectOpen):
             self.CTR = ProjectController(self, self.Log)
             self.Controler = self.CTR
-            result = self.CTR.LoadProject(projectOpen, buildpath)
+            result, err = self.CTR.LoadProject(projectOpen, buildpath)
             if not result:
                 self.LibraryPanel.SetController(self.Controler)
                 self.ProjectTree.Enable(True)
--- a/ProjectController.py	Tue Jan 17 13:30:38 2017 +0300
+++ b/ProjectController.py	Tue Jan 17 16:34:24 2017 +0300
@@ -1262,7 +1262,7 @@
     def _UpdateButtons(self):
         self.EnableMethod("_Clean", os.path.exists(self._getBuildPath()))
         self.ShowMethod("_showIECcode", os.path.isfile(self._getIECcodepath()))
-        if not self.UpdateMethodsFromPLCStatus():
+        if self.AppFrame is not None and not self.UpdateMethodsFromPLCStatus():
             self.AppFrame.RefreshStatusToolBar()
         
     def UpdateButtons(self):