gnome-games r8421 - trunk/libgames-support



Author: chpe
Date: Tue Jan  6 18:18:09 2009
New Revision: 8421
URL: http://svn.gnome.org/viewvc/gnome-games?rev=8421&view=rev

Log:
Make the old-style theme backend work.

Modified:
   trunk/libgames-support/games-card-theme-preimage.c
   trunk/libgames-support/games-card-theme-private.h
   trunk/libgames-support/games-card-theme-sliced.c

Modified: trunk/libgames-support/games-card-theme-preimage.c
==============================================================================
--- trunk/libgames-support/games-card-theme-preimage.c	(original)
+++ trunk/libgames-support/games-card-theme-preimage.c	Tue Jan  6 18:18:09 2009
@@ -52,8 +52,11 @@
 void
 _games_card_theme_preimage_clear_sized_theme_data (GamesCardThemePreimage *theme)
 {
-  if (GAMES_CARD_THEME_PREIMAGE_GET_CLASS (theme)->clear_sized_theme_data)
-    GAMES_CARD_THEME_PREIMAGE_GET_CLASS (theme)->clear_sized_theme_data (theme);
+  void (* clear_sized_theme_data) (GamesCardThemePreimage *) =
+    GAMES_CARD_THEME_PREIMAGE_GET_CLASS (theme)->clear_sized_theme_data;
+
+  if (clear_sized_theme_data)
+    clear_sized_theme_data (theme);
 
 #ifdef INSTRUMENT_LOADING
   /* Reset the time */
@@ -203,8 +206,6 @@
 {
   theme->card_size.width = theme->card_size.height = -1;
   theme->theme_name = NULL;
-
-  theme->prescaled = FALSE;
 }
 
 static void

Modified: trunk/libgames-support/games-card-theme-private.h
==============================================================================
--- trunk/libgames-support/games-card-theme-private.h	(original)
+++ trunk/libgames-support/games-card-theme-private.h	Tue Jan  6 18:18:09 2009
@@ -83,8 +83,6 @@
   guint theme_loaded : 1;
   guint size_available : 1;
 
-  guint prescaled : 1;
-
   cairo_font_options_t *font_options;
 };
 

Modified: trunk/libgames-support/games-card-theme-sliced.c
==============================================================================
--- trunk/libgames-support/games-card-theme-sliced.c	(original)
+++ trunk/libgames-support/games-card-theme-sliced.c	Tue Jan  6 18:18:09 2009
@@ -75,8 +75,6 @@
   /* Reset the time */
   totaltime = 0;
 #endif
-
-  GAMES_CARD_THEME_PREIMAGE_CLASS (games_card_theme_sliced_parent_class)->clear_sized_theme_data (preimage_card_theme);
 }
 
 static gboolean
@@ -132,7 +130,7 @@
 #endif
 
   g_return_val_if_fail (preimage_card_theme->cards_preimage != NULL, FALSE);
-  g_return_val_if_fail (preimage_card_theme->prescaled
+  g_return_val_if_fail (theme->prescaled
                         || theme->source != NULL, FALSE);
 
   theme->source =



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