[gnome-2048] Resize also tiles to be shown
- From: Juan R. Garcia Blanco <juanrgar src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-2048] Resize also tiles to be shown
- Date: Fri, 20 Feb 2015 22:59:59 +0000 (UTC)
commit 2c36cb58f301dba34ee913dc1862fc84831465d4
Author: Juan R. GarcĂa Blanco <juanrgar gmail com>
Date: Fri Feb 20 23:58:50 2015 +0100
Resize also tiles to be shown
This fixes a problem when restoring the game to a maximized window. View
allocation changes while showing the tiles; at that point tiles are in
the nxt structure, and they were not resized properly.
src/game.vala | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/src/game.vala b/src/game.vala
index 39f38f9..e1a938f 100644
--- a/src/game.vala
+++ b/src/game.vala
@@ -257,9 +257,11 @@ public class Game : GLib.Object
_background[i,j].resize (x, y, tile_width, tile_height);
- if (_foreground_cur[i,j] != null) {
+ if (_foreground_cur[i,j] != null)
_foreground_cur[i,j].resize (x, y, tile_width, tile_height);
- }
+
+ if (_foreground_nxt[i,j] != null)
+ _foreground_nxt[i,j].resize (x, y, tile_width, tile_height);
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]