controls/VariablePanel.py
changeset 1847 6198190bc121
parent 1846 14b40afccd69
child 1850 614396cbffbf
equal deleted inserted replaced
1846:14b40afccd69 1847:6198190bc121
   873                 type_menu.AppendMenu(wx.NewId(), category["name"], confnode_datatype_menu)
   873                 type_menu.AppendMenu(wx.NewId(), category["name"], confnode_datatype_menu)
   874 
   874 
   875     def BuildProjectTypesMenu(self, type_menu, classtype):
   875     def BuildProjectTypesMenu(self, type_menu, classtype):
   876         # build a submenu containing function block types
   876         # build a submenu containing function block types
   877         bodytype = self.Controler.GetEditedElementBodyType(self.TagName)
   877         bodytype = self.Controler.GetEditedElementBodyType(self.TagName)
   878         pouname, poutype = self.Controler.GetEditedElementType(self.TagName)
   878         _pouname, poutype = self.Controler.GetEditedElementType(self.TagName)
   879         if classtype in ["Input", "Output", "InOut", "External", "Global"] or \
   879         if classtype in ["Input", "Output", "InOut", "External", "Global"] or \
   880            poutype != "function" and bodytype in ["ST", "IL"]:
   880            poutype != "function" and bodytype in ["ST", "IL"]:
   881             functionblock_menu = wx.Menu(title='')
   881             functionblock_menu = wx.Menu(title='')
   882             fbtypes = self.Controler.GetFunctionBlockTypes(self.TagName)
   882             fbtypes = self.Controler.GetFunctionBlockTypes(self.TagName)
   883             for functionblock_type in fbtypes:
   883             for functionblock_type in fbtypes: