def addTrackObject(self, track_object): if track_object.track is not None: raise TrackError() if track_object.gnl_object in list(self.composition): raise TrackError() track_object.makeBin() track_object.track = self start_insort_right(self.track_objects, track_object) self.updateDefaultSources() try: self.composition.add(track_object.gnl_object) except gst.AddError: raise TrackError() self._connectToTrackObjectSignals(track_object) self._updateMaxPriority() self._connectToTrackObject(track_object) self.emit('track-object-added', track_object) if self._update_transitions: self.updateTransitions()
def _trackObjectStartChangedCb(self, track_object, start): self.track_objects.remove(track_object) start_insort_right(self.track_objects, track_object)