gnome-games r8807 - trunk/aisleriot
- From: nroberts svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-games r8807 - trunk/aisleriot
- Date: Fri, 6 Mar 2009 02:36:45 +0000 (UTC)
Author: nroberts
Date: Fri Mar 6 02:36:45 2009
New Revision: 8807
URL: http://svn.gnome.org/viewvc/gnome-games?rev=8807&view=rev
Log:
[aisleriot-card] Fix the card flipping animation
In revision 8475 the code to retrieve the card texture was moved to
before the card number was changed to compensate for the card being
flipped. Therefore the card was always drawn as if it is not rotated
to show the other side.
Modified:
trunk/aisleriot/card.c
Modified: trunk/aisleriot/card.c
==============================================================================
--- trunk/aisleriot/card.c (original)
+++ trunk/aisleriot/card.c Fri Mar 6 02:36:45 2009
@@ -262,12 +262,6 @@
card_num = priv->card;
- tex = games_card_textures_cache_get_card_texture (priv->cache, card_num);
- if (G_UNLIKELY (tex == COGL_INVALID_HANDLE))
- return;
-
- clutter_actor_get_allocation_box (actor, &alloc_box);
-
x_angle = clutter_actor_get_rotationx (actor, CLUTTER_X_AXIS,
NULL, NULL, NULL);
y_angle = clutter_actor_get_rotationx (actor, CLUTTER_Y_AXIS,
@@ -286,6 +280,12 @@
x_swapped = TRUE;
}
+ tex = games_card_textures_cache_get_card_texture (priv->cache, card_num);
+ if (G_UNLIKELY (tex == COGL_INVALID_HANDLE))
+ return;
+
+ clutter_actor_get_allocation_box (actor, &alloc_box);
+
/* Ideally we would just swap the texture coordinates, but Cogl
won't let you do this */
if (x_swapped) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]