Ejemplo n.º 1
0
 def __init__(self, instance, element, timeline, **kwargs):
     self.app = instance
     self.element = element
     self.timeline = timeline
     self.movable = True
     self.current_pixbuf = TRIMBAR_PIXBUF
     GooCanvas.CanvasImage.__init__(self,
         pixbuf=self.current_pixbuf,
         line_width=0,
         pointer_events=GooCanvas.CanvasPointerEvents.FILL,
         **kwargs)
     View.__init__(self, instance, GES.EditMode.EDIT_TRIM)
     Zoomable.__init__(self)
     Loggable.__init__(self)
Ejemplo n.º 2
0
 def __init__(self, instance, element, interpolator, height=LAYER_HEIGHT_EXPANDED,
     **kwargs):
     super(Curve, self).__init__(**kwargs)
     View.__init__(self)
     Zoomable.__init__(self)
     self.app = instance
     self.keyframes = {}
     self.height = float(height)
     self.element = element
     self.props.pointer_events = goocanvas.EVENTS_STROKE
     self.interpolator = interpolator
     self._focused_kf = None
     self.normal()
     self.set_simple_transform(0, -KW_LABEL_Y_OVERFLOW, 1.0, 0)
Ejemplo n.º 3
0
 def __init__(self, instance, element, timeline, **kwargs):
     self.app = instance
     self.element = element
     self.timeline = timeline
     self.movable = True
     self.current_pixbuf = TRIMBAR_PIXBUF
     goocanvas.Image.__init__(self,
         pixbuf=self.current_pixbuf,
         line_width=0,
         pointer_events=goocanvas.EVENTS_FILL,
         **kwargs)
     View.__init__(self, instance, ges.EDIT_MODE_TRIM)
     Zoomable.__init__(self)
     Loggable.__init__(self)
Ejemplo n.º 4
0
 def __init__(self, instance, element, interpolator, height=LAYER_HEIGHT_EXPANDED, **kwargs):
     super(Curve, self).__init__(**kwargs)
     View.__init__(self)
     Zoomable.__init__(self)
     self.app = instance
     self.keyframes = {}
     self.height = float(height)
     self.element = element
     # FIXME PyGI port
     #self.props.pointer_events = GooCanvas.EVENTS_STROKE
     self.interpolator = interpolator
     self._focused_kf = None
     self.normal()
     self.set_simple_transform(0, -KW_LABEL_Y_OVERFLOW, 1.0, 0)
Ejemplo n.º 5
0
    def __init__(self, instance, element, track, timeline, utrack):
        goocanvas.Group.__init__(self)
        View.__init__(self, instance)
        Zoomable.__init__(self)
        Loggable.__init__(self)
        self.ref = Zoomable.nsToPixel(10000000000)
        self.app = instance
        self.track = track
        self.utrack = utrack
        self.timeline = timeline
        self.namewidth = 0
        self.nameheight = 0
        self._element = None
        self._settings = None
        self.movable = True

        self.bg = goocanvas.Rect(height=self.height, line_width=1)

        self.name = goocanvas.Text(
            x=NAME_HOFFSET + NAME_PADDING,
            y=NAME_VOFFSET + NAME_PADDING,
            operator=cairo.OPERATOR_ADD,
            alignment=pango.ALIGN_LEFT)
        self.namebg = goocanvas.Rect(
            radius_x=2,
            radius_y=2,
            x=NAME_HOFFSET,
            y=NAME_VOFFSET,
            line_width=0)

        self.start_handle = StartHandle(self.app, element, timeline, height=self.height)
        self.end_handle = EndHandle(self.app, element, timeline, height=self.height)

        self._selec_indic = goocanvas.Rect(
            visibility=goocanvas.ITEM_INVISIBLE,
            line_width=0.0,
            height=self.height)

        self.element = element
        element.selected = Selected()
        element.selected.connect("selected-changed", self.selectedChangedCb)
        obj = self.element.get_timeline_object()

        self.settings = instance.settings
        self.unfocus()