totem r5983 - in trunk: . src



Author: hadess
Date: Mon Feb 16 17:28:30 2009
New Revision: 5983
URL: http://svn.gnome.org/viewvc/totem?rev=5983&view=rev

Log:
2009-02-16  Bastien Nocera  <hadess hadess net>

	* src/totem-video-thumbnailer.c (create_gallery): Only ever
	print progress when we are asked to do so. Fix filename
	in galleries showing up unescaped when a URI is passed as 
	input



Modified:
   trunk/ChangeLog
   trunk/src/totem-video-thumbnailer.c

Modified: trunk/src/totem-video-thumbnailer.c
==============================================================================
--- trunk/src/totem-video-thumbnailer.c	(original)
+++ trunk/src/totem-video-thumbnailer.c	Mon Feb 16 17:28:30 2009
@@ -51,7 +51,7 @@
 #endif
 
 /* The main() function controls progress in the first and last 10% */
-#define PRINT_PROGRESS(p) { g_printf ("%f%% complete\n", p); }
+#define PRINT_PROGRESS(p) { if (print_progress) g_printf ("%f%% complete\n", p); }
 #define MIN_PROGRESS 10.0
 #define MAX_PROGRESS 90.0
 
@@ -644,7 +644,16 @@
 
 	/* Build the header information */
 	duration_text = totem_time_to_string (stream_length * 1000);
-	filename = g_path_get_basename (input);
+	filename = NULL;
+	if (strstr (input, "://")) {
+		char *local;
+		local = g_filename_from_uri (input, NULL, NULL);
+		filename = g_path_get_basename (local);
+		g_free (local);
+	}
+	if (filename == NULL)
+		filename = g_path_get_basename (input);
+
 	header_text = g_strdup_printf (_("<b>%s</b>: %s\n<b>%s</b>: %d\303\227%d\n<b>%s</b>: %s"),
 				       _("Filename"),
 				       filename,



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