gnome-games r8537 - trunk/libgames-support
- From: chpe svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-games r8537 - trunk/libgames-support
- Date: Thu, 8 Jan 2009 23:44:34 +0000 (UTC)
Author: chpe
Date: Thu Jan 8 23:44:34 2009
New Revision: 8537
URL: http://svn.gnome.org/viewvc/gnome-games?rev=8537&view=rev
Log:
Blacklist these themes, since we have the same ones in g-g-extra-data,
and ours render faster.
Modified:
trunk/libgames-support/games-card-theme-kde.c
Modified: trunk/libgames-support/games-card-theme-kde.c
==============================================================================
--- trunk/libgames-support/games-card-theme-kde.c (original)
+++ trunk/libgames-support/games-card-theme-kde.c Thu Jan 8 23:44:34 2009
@@ -70,6 +70,26 @@
#define KDE_BACKDECK_PYSOL_KEY "PySol"
#define KDE_BACKDECK_SVG_KEY "SVG"
+static gboolean
+get_is_blacklisted (const char *filename)
+{
+ /* Let's blacklist these themes, since they exist in g-g-extra-data too,
+ * and our variants render faster.
+ */
+ static const char *blacklist[] = {
+ "svg-dondorf",
+ "svg-nicu-ornamental",
+ "svg-gm-paris"
+ };
+ guint i;
+
+ for (i = 0; i < G_N_ELEMENTS (blacklist); ++i)
+ if (strcmp (filename, blacklist[i]) == 0)
+ return TRUE;
+
+ return FALSE;
+}
+
#ifdef HAVE_RSVG_BBOX
static CardBbox *
@@ -254,6 +274,12 @@
GKeyFile *key_file = NULL;
char *svg_filename = NULL, *name = NULL, *display_name, *pref_name;
+ if (get_is_blacklisted (filename)) {
+ _games_debug_print (GAMES_DEBUG_CARD_THEME,
+ "KDE card theme %s is blacklisted\n", filename);
+ return NULL;
+ }
+
base_path = g_build_filename (path, filename, NULL);
if (!g_file_test (path, G_FILE_TEST_IS_DIR))
goto out;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]