objdictgen/subindextable.py
changeset 277 426552c56a5a
parent 273 58b39f97e352
child 281 685d9a26e4f9
equal deleted inserted replaced
276:eada6c6c2e87 277:426552c56a5a
   486                     entry_infos = self.Manager.GetEntryInfos(index)
   486                     entry_infos = self.Manager.GetEntryInfos(index)
   487                     if not entry_infos["struct"] & OD_MultipleSubindexes or row != 0:
   487                     if not entry_infos["struct"] & OD_MultipleSubindexes or row != 0:
   488                         subentry_infos = self.Manager.GetSubentryInfos(index, subindex)
   488                         subentry_infos = self.Manager.GetSubentryInfos(index, subindex)
   489                         typeinfos = self.Manager.GetEntryInfos(subentry_infos["type"])
   489                         typeinfos = self.Manager.GetEntryInfos(subentry_infos["type"])
   490                         if subentry_infos["pdo"] and typeinfos:
   490                         if subentry_infos["pdo"] and typeinfos:
   491                             bus_id = '.'.join(map(str,self.Parent.GetBusId()))
   491                             bus_id = '.'.join(map(str,self.ParentWindow.GetBusId()))
   492                             node_id = self.Parent.GetCurrentNodeId()
   492                             node_id = self.ParentWindow.GetCurrentNodeId()
   493                             size = typeinfos["size"]
   493                             size = typeinfos["size"]
   494                             data = wx.TextDataObject(str(("%s%s.%d.%d.%d"%(SizeConversion[size], bus_id, node_id, index, subindex), "location")))
   494                             data = wx.TextDataObject(str(("%s%s.%d.%d.%d"%(SizeConversion[size], bus_id, node_id, index, subindex), "location")))
   495                             dragSource = wx.DropSource(self.SubindexGrid)
   495                             dragSource = wx.DropSource(self.SubindexGrid)
   496                             dragSource.SetData(data)
   496                             dragSource.SetData(data)
   497                             dragSource.DoDragDrop()
   497                             dragSource.DoDragDrop()