brasero r1969 - in trunk: . src



Author: philippr
Date: Fri Feb 20 10:05:10 2009
New Revision: 1969
URL: http://svn.gnome.org/viewvc/brasero?rev=1969&view=rev

Log:
2009-02-20  Philippe Rouquier  <ykw localhost localdomain>

	Make sure we don't create a second structure when among flags already
	set we find a pair of flags equal or encompassing those we want to add

	* src/burn-plugin.c (brasero_plugin_set_flags_real):

Modified:
   trunk/ChangeLog
   trunk/src/burn-plugin.c

Modified: trunk/src/burn-plugin.c
==============================================================================
--- trunk/src/burn-plugin.c	(original)
+++ trunk/src/burn-plugin.c	Fri Feb 20 10:05:10 2009
@@ -487,6 +487,14 @@
 		flags->media = media;
 		flags_list = g_slist_prepend (flags_list, flags);
 	}
+	else for (pair = flags->pairs; pair; pair = pair->next) {
+		/* have a look at the BraseroPluginFlagPair to see if there
+		 * is an exactly similar pair of flags or at least which
+		 * encompasses it to avoid redundancy. */
+		if ((pair->supported & supported) == supported
+		&&  (pair->compulsory & compulsory) == compulsory)
+			return flags_list;
+	}
 
 	pair = g_new0 (BraseroPluginFlagPair, 1);
 	pair->supported = supported;



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