summaryrefslogtreecommitdiffstats
path: root/pokemodr/ItemUI.cpp
diff options
context:
space:
mode:
authorBen Boeckel <MathStuf@gmail.com>2008-04-27 15:15:17 +0000
committerBen Boeckel <MathStuf@gmail.com>2008-04-27 15:15:17 +0000
commit807071d35159de0660f9df31c48d5bf895ca3622 (patch)
treea1e9dbdc1e58b91cd2e4a5e472597b0204ccb41d /pokemodr/ItemUI.cpp
parentf444f5a45e9325644a360f656176d47d7f540f52 (diff)
[FIX] Pokemod objects now know about parents
[FIX] Project includes are now relative [FIX] Headers included for better detection of invalid headers [FIX] Validation code commented out so it can be done better git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@111 6ecfd1a5-f3ed-3746-8530-beee90d26b22
Diffstat (limited to 'pokemodr/ItemUI.cpp')
-rw-r--r--pokemodr/ItemUI.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/pokemodr/ItemUI.cpp b/pokemodr/ItemUI.cpp
index 70cf36b5..9257b0a8 100644
--- a/pokemodr/ItemUI.cpp
+++ b/pokemodr/ItemUI.cpp
@@ -15,16 +15,16 @@
* with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-// General includes
-#include <BugCatcher.h>
-#include <Exception.h>
+// Header include
+#include "ItemUI.h"
// Pokemod includes
-#include <ItemType.h>
-#include <Pokemod.h>
+#include "../pokemod/ItemType.h"
+#include "../pokemod/Pokemod.h"
-// Header include
-#include "ItemUI.h"
+// General includes
+#include "../general/BugCatcher.h"
+#include "../general/Exception.h"
ItemUI::ItemUI(Item* item, QWidget* parent) :
ObjectUI(parent),
@@ -41,13 +41,13 @@ ItemUI::ItemUI(Item* item, QWidget* parent) :
void ItemUI::refreshGui()
{
varType->clear();
- for (int i = 0; i < m_item->pokemod()->itemTypeCount(); ++i)
+ for (int i = 0; i < static_cast<const Pokemod*>(m_item->pokemod())->itemTypeCount(); ++i)
{
- const ItemType* itemType = m_item->pokemod()->itemType(i);
+ const ItemType* itemType = static_cast<const Pokemod*>(m_item->pokemod())->itemType(i);
varType->addItem(itemType->name());
varType->setItemData(i, itemType->id());
}
- varPrice->setMaximum(m_item->pokemod()->rules()->maxMoney());
+ varPrice->setMaximum(static_cast<const Pokemod*>(m_item->pokemod())->rules()->maxMoney());
}
void ItemUI::setGui()