wxglade_hmi/wxglade_hmi.py
changeset 1739 ec153828ded2
parent 1736 7e61baa047f0
child 1740 b789b695b5c6
equal deleted inserted replaced
1738:d2e979738700 1739:ec153828ded2
    34 
    34 
    35 
    35 
    36 class WxGladeHMI(PythonFileCTNMixin):
    36 class WxGladeHMI(PythonFileCTNMixin):
    37 
    37 
    38     ConfNodeMethods = [
    38     ConfNodeMethods = [
    39         {"bitmap" : "editWXGLADE",
    39         {
    40          "name" : _("WXGLADE GUI"),
    40             "bitmap":    "editWXGLADE",
    41          "tooltip" : _("Edit a WxWidgets GUI with WXGlade"),
    41             "name":    _("WXGLADE GUI"),
    42          "method" : "_editWXGLADE"},
    42             "tooltip": _("Edit a WxWidgets GUI with WXGlade"),
       
    43             "method":   "_editWXGLADE"
       
    44         },
    43     ]
    45     ]
    44 
    46 
    45     def GetIconName(self):
    47     def GetIconName(self):
    46         return "wxGlade"
    48         return "wxGlade"
    47 
    49 
    95             wxgfile.close()
    97             wxgfile.close()
    96 
    98 
    97             for node in wxgtree.childNodes[1].childNodes:
    99             for node in wxgtree.childNodes[1].childNodes:
    98                 if node.nodeType == wxgtree.ELEMENT_NODE:
   100                 if node.nodeType == wxgtree.ELEMENT_NODE:
    99                     hmi_frames.append({
   101                     hmi_frames.append({
   100                         "name" : node.getAttribute("name"),
   102                         "name": node.getAttribute("name"),
   101                         "class" : node.getAttribute("class"),
   103                         "class": node.getAttribute("class"),
   102                         "handlers" : [
   104                         "handlers": [
   103                             hnode.firstChild.data for hnode in
   105                             hnode.firstChild.data for hnode in
   104                             node.getElementsByTagName("handler")]})
   106                             node.getElementsByTagName("handler")]})
   105 
   107 
   106             hmipyfile_path=os.path.join(self._getBuildPath(), "hmi.py")
   108             hmipyfile_path=os.path.join(self._getBuildPath(), "hmi.py")
   107             if wx.Platform == '__WXMSW__':
   109             if wx.Platform == '__WXMSW__':