[pitivi] ui: expose rage and hatred at gst.CLOCK_TIME_NONE



commit 206f3a05e0c6d86cc26c771fc7a56abdd3b281f3
Author: Edward Hervey <bilboed bilboed com>
Date:   Sat May 30 20:48:03 2009 +0200

    ui: expose rage and hatred at gst.CLOCK_TIME_NONE

 pitivi/ui/trackobject.py   |    6 +++++-
 pitivi/ui/zoominterface.py |    4 +++-
 2 files changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/pitivi/ui/trackobject.py b/pitivi/ui/trackobject.py
index 2a0fd48..d4da124 100644
--- a/pitivi/ui/trackobject.py
+++ b/pitivi/ui/trackobject.py
@@ -393,7 +393,11 @@ class TrackObject(View, goocanvas.Group, Zoomable):
         self._update()
 
     def _update(self):
-        x = self.nsToPixel(self.element.start)
+        try:
+            x = self.nsToPixel(self.element.start)
+        except Exception, e:
+            print self.element.start
+            raise Exception(e)
         y = (self.height + LAYER_SPACING) * self.element.priority
         self.set_simple_transform(x, y, 1, 0)
         width = self.nsToPixel(self.element.duration)
diff --git a/pitivi/ui/zoominterface.py b/pitivi/ui/zoominterface.py
index e7c01f9..de278e7 100644
--- a/pitivi/ui/zoominterface.py
+++ b/pitivi/ui/zoominterface.py
@@ -106,7 +106,9 @@ class Zoomable(object):
         Returns the pixel equivalent of the given duration, according to the
         set zoom ratio
         """
-        if long(duration) == long(gst.CLOCK_TIME_NONE):
+        ## DIE YOU CUNTMUNCH CLOCK_TIME_NONE UBER STUPIDITY OF CRACK BINDINGS !!!!!!
+        if duration == 18446744073709551615 or \
+               long(duration) == long(gst.CLOCK_TIME_NONE):
             return 0
         return int((float(duration) / gst.SECOND) * cls.zoomratio)
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]