Esempio n. 1
0
 def addSeq(self, e=None):       
     """ create a new sequence. """
     if self.parent.project.name != "":
         dlg = wx.TextEntryDialog(self,'Sequence Name:', 'New Sequence Settings')
         dlg.SetValue("")
         if dlg.ShowModal() == wx.ID_OK:
             self.seqbox.Append(dlg.GetValue())
             self.parent.project.sequences[dlg.GetValue()] = project.sequence("")
             dlg.Destroy()
             self.parent.project.save = True
     else:
         dlg = wx.MessageDialog(self, 'Please create a new robot first.', 'Error', wx.OK|wx.ICON_EXCLAMATION)
         dlg.ShowModal()
         dlg.Destroy()
Esempio n. 2
0
 def save(self):            
     if self.curseq != "":
         self.parent.project.sequences[self.curseq] = project.sequence()
         for i in range(self.tranbox.GetCount()):
             self.parent.project.sequences[self.curseq].append(self.tranbox.GetString(i).replace(",","|"))               
         self.parent.project.save = True