def readProgramConf(self, pConf): for conf in pConf: try: media = GstTrack(uuid=conf[0]) self.addMediaAt(media, conf[1]['pos']) media.updateConfiguration(conf[1]) except Exception as e: QtGui.QMessageBox.critical(None, 'Error Message', 'Error during file reading: ' + ' '.join([str(i) for i in e.args]))
def readProgramConf(self, pConf): self.resetLayout() for conf in pConf: _uuid = conf[0] conf = conf[1] if(conf['pos'][0] > self.currentIndex()): self.addPage() self.setCurrentIndex(self.currentIndex() + 1) media = GstTrack(uuid=_uuid) self.addMediaAt(media, (-1, conf['pos'][1], conf['pos'][2])) media.updateConfiguration(conf) self.setCurrentIndex(0)
def copyAt(self, widget, pos): media = GstTrack() pos = (self.currentIndex(), pos[1], pos[2]) self.addMediaAt(media, pos) media.updateConfiguration(deepcopy(widget.media.conf))