rpms/totem/F-11 opensub-fix-warning.patch, NONE, 1.1 totem.spec, 1.249, 1.250

Bastien Nocera hadess at fedoraproject.org
Tue Oct 20 15:05:03 UTC 2009


Author: hadess

Update of /cvs/pkgs/rpms/totem/F-11
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv28629

Modified Files:
	totem.spec 
Added Files:
	opensub-fix-warning.patch 
Log Message:
* Tue Oct 20 2009 Bastien Nocera <bnocera at redhat.com> 2.26.4-3
- Fix warning when using OpenSubtitles plugin (#497210)


opensub-fix-warning.patch:
 opensubtitles.py |    9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

--- NEW FILE opensub-fix-warning.patch ---
>From 5a1b3c0fe2c23e7993d6880efde2bfc08bde1e5c Mon Sep 17 00:00:00 2001
From: Philip Withnall <philip at tecnocode.co.uk>
Date: Sun, 19 Jul 2009 22:51:41 +0000
Subject: Small UI and compatibility fixes to the OpenSubtitles plugin

2009-07-19  Philip Withnall  <philip at tecnocode.co.uk>

	* src/plugins/opensubtitles/opensubtitles.py:
	* src/plugins/opensubtitles/opensubtitles.ui: Fixed underlines in the
	OpenSubtitles interface, and removed use of a GLib 2.18-only function
---
diff --git a/src/plugins/opensubtitles/opensubtitles.py b/src/plugins/opensubtitles/opensubtitles.py
index 3c5c3bc..08f52ea 100644
--- a/src/plugins/opensubtitles/opensubtitles.py
+++ b/src/plugins/opensubtitles/opensubtitles.py
@@ -4,7 +4,7 @@ gobject.threads_init()
 import xmlrpclib
 import threading
 import xdg.BaseDirectory
-from os import sep
+from os import sep, path, mkdir
 import gettext
 import pango
 
@@ -517,7 +517,12 @@ class OpenSubtitles(totem.Plugin):
             if not filename:
                 directory = gio.File(xdg.BaseDirectory.xdg_cache_home + sep + 'totem' + sep + 'subtitles' + sep) 
                 if not directory.query_exists():
-                    directory.make_directory_with_parents()
+                    if not path.exists (xdg.BaseDirectory.xdg_cache_home + sep + 'totem' + sep):
+                        mkdir (xdg.BaseDirectory.xdg_cache_home + sep + 'totem' + sep)
+                    if not path.exists (xdg.BaseDirectory.xdg_cache_home + sep + 'totem' + sep + 'subtitles' + sep):
+                        mkdir (xdg.BaseDirectory.xdg_cache_home + sep + 'totem' + sep + 'subtitles' + sep)
+                    # FIXME: We can't use this function until we depend on GLib (PyGObject) 2.18
+                    # directory.make_directory_with_parents()
 
                 file = gio.File(self.filename)
                 movie_name = file.get_basename().rpartition('.')[0]


Index: totem.spec
===================================================================
RCS file: /cvs/pkgs/rpms/totem/F-11/totem.spec,v
retrieving revision 1.249
retrieving revision 1.250
diff -u -p -r1.249 -r1.250
--- totem.spec	20 Oct 2009 14:08:45 -0000	1.249
+++ totem.spec	20 Oct 2009 15:05:03 -0000	1.250
@@ -9,7 +9,7 @@
 Summary: Movie player for GNOME
 Name: totem
 Version: 2.26.4
-Release: 2%{?dist}
+Release: 3%{?dist}
 License: GPLv2+ with exceptions
 Group: Applications/Multimedia
 URL: http://projects.gnome.org/totem/
@@ -17,6 +17,8 @@ Source0: http://download.gnome.org/sourc
 Source1: totem-bin-backend-ondemand.sh
 # Will be removed when we switch to playbin2
 Patch0: 0001-Set-the-PA-stream-volume-from-Totem.patch
+# http://git.gnome.org/cgit/totem/commit/?id=5a1b3c0fe2c23e7993d6880efde2bfc08bde1e5c
+Patch1: opensub-fix-warning.patch
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) 
 
 Requires(pre): GConf2 >= 2.14
@@ -210,6 +212,7 @@ audio and video files in the properties 
 %setup -q -c
 pushd totem-%{version}/
 %patch0 -p1 -b .pulsesink-vol
+%patch1 -p1 -b .opensub
 popd
 # Whatever needs to be changed in both copies do here
 ## remember to update me when changing %doc
@@ -483,6 +486,9 @@ fi
 %endif
 
 %changelog
+* Tue Oct 20 2009 Bastien Nocera <bnocera at redhat.com> 2.26.4-3
+- Fix warning when using OpenSubtitles plugin (#497210)
+
 * Tue Oct 20 2009 Bastien Nocera <bnocera at redhat.com> 2.26.4-2
 - Update pulsesink patch to use cubic volumes (#512090)
 




More information about the fedora-extras-commits mailing list