[jokosher-devel] Patches for GNOME Audio Profiles and Extensions API



One patch removes a debugging print from GNOME Audio Profiles.py.  The
other adds and uses a decorator around the exported functions.  The
decorator does not allow exceptions to pass beyond the Jokosher API and
returns a -1 error code instead.

I have 2 patches as I checked out Jokosher and the extensions at different
times and places.
Index: GNOMEAudioProfiles.py
===================================================================
--- GNOMEAudioProfiles.py	(revision 812)
+++ GNOMEAudioProfiles.py	(working copy)
@@ -8,14 +8,13 @@
 
 EXTENSION_NAME = "GNOME Audio Profiles"
 EXTENSION_DESCRIPTION = "Imports GNOME Audio Profiles into jokosher"
-EXTENSION_VERSION = "0.0.1"
+EXTENSION_VERSION = "0.0.2"
 _GCONF_PROFILE_PATH = "/system/gstreamer/0.10/audio/profiles/"
 _GCONF_PROFILE_LIST_PATH = "/system/gstreamer/0.10/audio/global/profile_list"
 
 def startup(api):
 	_GCONF = gconf.client_get_default()
 	profiles = _GCONF.get_list(_GCONF_PROFILE_LIST_PATH, 1)
-	print profiles
 	for name in profiles:
 		if (_GCONF.get_bool(_GCONF_PROFILE_PATH + name + "/active")):
 			description = _GCONF.get_string(_GCONF_PROFILE_PATH + name + "/name") + " (.%s)"
Index: Jokosher/Extension.py
===================================================================
--- Jokosher/Extension.py	(revision 808)
+++ Jokosher/Extension.py	(working copy)
@@ -459,7 +459,7 @@
 		if not description or not extension and not pipelineString:
 			return 1
 		try:
-			bin = gst.gst_parse_bin_from_description(encodeBin)
+			bin = gst.gst_parse_bin_from_description("fakesrc ! " + encodeBin, True)
 			del bin
 		except gobject.GError:
 			return 2


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