IDE: fix About dialog not showing (wxPython4 sequel), update copyright section. wxPython4
authorEdouard Tisserant <edouard.tisserant@gmail.com>
Sat, 30 Jul 2022 01:31:17 +0200
branchwxPython4
changeset 3570 eb915a9fdcb0
parent 3569 419f17564583
child 3571 fdd4b171ac6c
IDE: fix About dialog not showing (wxPython4 sequel), update copyright section.
BeremizIDE.py
PLCOpenEditor.py
dialogs/AboutDialog.py
version.py
--- a/BeremizIDE.py	Sat Jul 30 10:11:59 2022 +0200
+++ b/BeremizIDE.py	Sat Jul 30 01:31:17 2022 +0200
@@ -37,6 +37,7 @@
 import wx.lib.buttons
 import wx.lib.statbmp
 import wx.stc
+import wx.adv
 
 
 import version
@@ -964,7 +965,15 @@
         self.Close()
 
     def OnAboutMenu(self, event):
-        info = version.GetAboutDialogInfo()
+        info = wx.adv.AboutDialogInfo()
+        info = version.GetAboutDialogInfo(info)
+        info.Name = "Beremiz"
+        info.Description = _("Open Source framework for automation, "
+            "implemented IEC 61131 IDE with constantly growing set of extensions "
+            "and flexible PLC runtime.")
+
+        info.Icon = wx.Icon(Bpath("images", "about_brz_logo.png"), wx.BITMAP_TYPE_PNG)
+
         ShowAboutDialog(self, info)
 
     def OnProjectTreeItemBeginEdit(self, event):
--- a/PLCOpenEditor.py	Sat Jul 30 10:11:59 2022 +0200
+++ b/PLCOpenEditor.py	Sat Jul 30 01:31:17 2022 +0200
@@ -31,6 +31,7 @@
 import getopt
 
 import wx
+import wx.adv
 
 import version
 import util.paths as paths
@@ -355,6 +356,7 @@
         open_pdf(os.path.join(beremiz_dir, "plcopen", "TC6_XML_V101.pdf"))
 
     def OnAboutMenu(self, event):
+        info = wx.adv.AboutDialogInfo()
         info = version.GetAboutDialogInfo()
         info.Name = "PLCOpenEditor"
         info.Description = _("PLCOpenEditor is part of Beremiz project.\n\n"
--- a/dialogs/AboutDialog.py	Sat Jul 30 10:11:59 2022 +0200
+++ b/dialogs/AboutDialog.py	Sat Jul 30 01:31:17 2022 +0200
@@ -34,6 +34,7 @@
 from __future__ import absolute_import
 import os
 import wx
+import wx.adv
 from wx.lib.agw.hyperlink import HyperLinkCtrl
 
 
@@ -172,4 +173,4 @@
     if os.name == "nt":
         AboutDialog(parent, info)
     else:
-        wx.AboutBox(info)
+        wx.adv.AboutBox(info)
--- a/version.py	Sat Jul 30 10:11:59 2022 +0200
+++ b/version.py	Sat Jul 30 01:31:17 2022 +0200
@@ -71,28 +71,23 @@
     return rev
 
 
-def GetAboutDialogInfo():
-    import wx
-    info = wx.AboutDialogInfo()
-
-    info.Name = "Beremiz"
+def GetAboutDialogInfo(info):
+
     info.Version = app_version
 
     info.Copyright = ""
+    info.Copyright += "(C) 2006-2022 Edouard Tisserant\n"
+    info.Copyright += "(C) 2003-2021 Mario de Sousa\n"
     info.Copyright += "(C) 2016-2018 Andrey Skvortsov\n"
-    info.Copyright += "(C) 2008-2018 Eduard Tisserant\n"
-    info.Copyright += "(C) 2008-2015 Laurent Bessard"
+    info.Copyright += "(C) 2006-2013 Laurent Bessard\n"
 
     info.WebSite = ("http://beremiz.org", "beremiz.org")
 
-    info.Description = _("Open Source framework for automation, "
-                         "implemented IEC 61131 IDE with constantly growing set of extensions "
-                         "and flexible PLC runtime.")
-
     info.Developers = (
+        "Edouard Tisserant <contact@beremiz.fr>",
+        "Mario de Sousa <msousa@fe.up.pt>",
         "Andrey Skvortsov <andrej.skvortzov@gmail.com>",
         "Sergey Surkov <surkov.sv@summatechnology.ru>",
-        "Edouard Tisserant <edouard.tisserant@gmail.com>",
         "Laurent Bessard <laurent.bessard@gmail.com>")
 
     info.License = (
@@ -118,8 +113,6 @@
         with open(license_path) as f:
             info.License += f.read()
 
-    info.Icon = wx.Icon(os.path.join(path, "images", "about_brz_logo.png"), wx.BITMAP_TYPE_PNG)
-
     info.Translators = (
         "Basque",
         "José Miguel Andonegi <jm.andonegi@gmail.com>, 2019",