From f4ee4327657b72b67c4d681695f570d008def39a Mon Sep 17 00:00:00 2001 From: "jean.chalard" Date: Sat, 22 Aug 2009 06:16:04 +0000 Subject: [PATCH] J : * Define floats in the .cpp instead of the .h (visual says I should, that's why) --- projects/mtg/include/CardGui.h | 8 ++++---- projects/mtg/src/CardGui.cpp | 6 ++++++ 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/projects/mtg/include/CardGui.h b/projects/mtg/include/CardGui.h index 763ccce90..56117d496 100644 --- a/projects/mtg/include/CardGui.h +++ b/projects/mtg/include/CardGui.h @@ -17,10 +17,10 @@ struct CardGui : public PlayGuiObject { JQuad* quad; public: - static const float Width = 28.0; - static const float Height = 40.0; - static const float BigWidth = 200.0; - static const float BigHeight = 285.0; + static const float Width; + static const float Height; + static const float BigWidth; + static const float BigHeight; MTGCardInstance* card; CardGui(MTGCardInstance* card, float x, float y); diff --git a/projects/mtg/src/CardGui.cpp b/projects/mtg/src/CardGui.cpp index eed602748..e38b7f169 100644 --- a/projects/mtg/src/CardGui.cpp +++ b/projects/mtg/src/CardGui.cpp @@ -7,6 +7,12 @@ #include "../include/MTGDefinitions.h" #include + +const float CardGui::Width = 28.0; +const float CardGui::Height = 40.0; +const float CardGui::BigWidth = 200.0; +const float CardGui::BigHeight = 285.0; + CardGui::CardGui(MTGCardInstance* card, float x, float y) : PlayGuiObject(Height, x, y, false), quad(cache.getQuad(card)), card(card) {} CardGui::CardGui(MTGCardInstance* card, const Pos& ref) : PlayGuiObject(Height, ref, false), quad(cache.getQuad(card)), card(card) {}