pitivi r1341 - in trunk: . pitivi
- From: edwardrv svn gnome org
- To: svn-commits-list gnome org
- Subject: pitivi r1341 - in trunk: . pitivi
- Date: Fri, 17 Oct 2008 11:50:48 +0000 (UTC)
Author: edwardrv
Date: Fri Oct 17 11:50:48 2008
New Revision: 1341
URL: http://svn.gnome.org/viewvc/pitivi?rev=1341&view=rev
Log:
* pitivi/device.py:
* pitivi/objectfactory.py:
* pitivi/plumber.py:
* pitivi/threads.py:
* pitivi/thumbnailer.py:
Remove even more gobject usage in core
Modified:
trunk/ChangeLog
trunk/pitivi/device.py
trunk/pitivi/objectfactory.py
trunk/pitivi/plumber.py
trunk/pitivi/threads.py
trunk/pitivi/thumbnailer.py
Modified: trunk/pitivi/device.py
==============================================================================
--- trunk/pitivi/device.py (original)
+++ trunk/pitivi/device.py Fri Oct 17 11:50:48 2008
@@ -24,9 +24,9 @@
Classes and Methods for Device handling and usage
"""
-import gobject
import gst
from objectfactory import ObjectFactory, SourceFactory
+from signalinterface import Signallable
try:
import dbus
@@ -64,7 +64,7 @@
return HalDeviceProbe()
return None
-class DeviceProbe(gobject.GObject):
+class DeviceProbe(object, Signallable):
"""
Allows listing of the various devices available.
@@ -73,18 +73,11 @@
This should be subclassed
"""
- __gsignals__ = {
- "device-added" : (gobject.SIGNAL_RUN_LAST,
- gobject.TYPE_NONE,
- (gobject.TYPE_PYOBJECT, )),
- "device-removed" : (gobject.SIGNAL_RUN_LAST,
- gobject.TYPE_NONE,
- (gobject.TYPE_PYOBJECT, ))
+ __signals__ = {
+ "device-added" : ["device"],
+ "device-removed" : ["device"]
}
- def __init__(self):
- gobject.GObject.__init__(self)
-
def getSourceDevices(self, media_type):
""" Returns a list of available SourceDeviceFactory for
the given mediatype
Modified: trunk/pitivi/objectfactory.py
==============================================================================
--- trunk/pitivi/objectfactory.py (original)
+++ trunk/pitivi/objectfactory.py Fri Oct 17 11:50:48 2008
@@ -179,6 +179,7 @@
stl = []
# FIXME : file is FileSourceFactory specific !
# FIXME : and it might not be a file:// but maybe a http://
+ # FIXME : we're only importing gobject for the markup ! Extract the code
filename = os.path.basename(unquote(self.name))
if not self.title:
stl.append(_("<b>%s</b><small>") % gobject.markup_escape_text(filename))
Modified: trunk/pitivi/plumber.py
==============================================================================
--- trunk/pitivi/plumber.py (original)
+++ trunk/pitivi/plumber.py Fri Oct 17 11:50:48 2008
@@ -32,7 +32,6 @@
#
# They should be provided by a generic sink provider
-import gobject
import gst
from gst import interfaces
@@ -59,11 +58,12 @@
# FIXME : YUCK, I'm guessing most of these issues (qos/max-lateness)
# have been solved since
if autovideosink.realsink:
- if "force-aspect-ratio"in [prop.name for prop in gobject.list_properties(autovideosink.realsink)]:
+ props = list(autovideosink.realsink.props)
+ if "force-aspect-ratio"in [prop.name for prop in props]:
autovideosink.realsink.set_property("force-aspect-ratio", True)
- if "qos"in [prop.name for prop in gobject.list_properties(autovideosink.realsink)]:
+ if "qos" in [prop.name for prop in props]:
autovideosink.realsink.set_property("qos", False)
- if "max-lateness"in [prop.name for prop in gobject.list_properties(autovideosink.realsink)]:
+ if "max-lateness"in [prop.name for prop in props]:
autovideosink.realsink.set_property("max-lateness", -1)
return autovideosink
Modified: trunk/pitivi/threads.py
==============================================================================
--- trunk/pitivi/threads.py (original)
+++ trunk/pitivi/threads.py Fri Oct 17 11:50:48 2008
@@ -23,7 +23,6 @@
"""
import threading
-import gobject
import gst
from signalinterface import Signallable
@@ -53,7 +52,7 @@
def run(self):
""" thread processing """
self.process()
- gobject.idle_add(self.emit, "done")
+ self.emit("done")
def process(self):
""" Implement this in subclasses """
Modified: trunk/pitivi/thumbnailer.py
==============================================================================
--- trunk/pitivi/thumbnailer.py (original)
+++ trunk/pitivi/thumbnailer.py Fri Oct 17 11:50:48 2008
@@ -28,16 +28,15 @@
import gst
from elements.singledecodebin import SingleDecodeBin
from elements.thumbnailsink import PixbufThumbnailSink
+from signalinterface import Signallable
-class Thumbnailer(gst.Pipeline):
+class Thumbnailer(gst.Pipeline, Signallable):
"""
Convenience pipeline to quickly create thumbnails for a given uri
"""
- __gsignals__ = {
- "thumbnail" : (gobject.SIGNAL_RUN_LAST,
- gobject.TYPE_NONE,
- ( gobject.TYPE_PYOBJECT, gobject.TYPE_UINT64 ))
+ __signals__ = {
+ "thumbnail" : ["pixbuf", "timestamp"]
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]