diff options
author | Ben Boeckel <MathStuf@gmail.com> | 2008-02-24 22:36:40 +0000 |
---|---|---|
committer | Ben Boeckel <MathStuf@gmail.com> | 2008-02-24 22:36:40 +0000 |
commit | 1e02a507f0b481465f5b47441479b98a81aee079 (patch) | |
tree | a6a108f187ec6f134c60470fdf317d0a77b2fdd3 /pokemodr/TileUI.cpp | |
parent | 26c9e526435474aa3e7f8e1be39dfb474dd8b368 (diff) | |
download | sigen-1e02a507f0b481465f5b47441479b98a81aee079.tar.gz sigen-1e02a507f0b481465f5b47441479b98a81aee079.tar.xz sigen-1e02a507f0b481465f5b47441479b98a81aee079.zip |
[FIX] KTabWidget now used rather than QTabWidget (though this kills Qt Designer interaction :\ )
[FIX] Minor fixes in PokeModr class
[DEL] Ref.{h, cpp}
[FIX] Ref enumerations now in Pokemod class
[FIX] new/delete used for subclasses in pokemod now
[FIX] Inclusion hell in pokemod (should compile faster)
[FIX] Spelling typos
git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@82 6ecfd1a5-f3ed-3746-8530-beee90d26b22
Diffstat (limited to 'pokemodr/TileUI.cpp')
-rw-r--r-- | pokemodr/TileUI.cpp | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/pokemodr/TileUI.cpp b/pokemodr/TileUI.cpp index 5e747675..fe8e4c58 100644 --- a/pokemodr/TileUI.cpp +++ b/pokemodr/TileUI.cpp @@ -28,7 +28,6 @@ #include <BugCatcher.h> #include <Exception.h> #include <ImageCache.h> -#include <Ref.h> #include <Pokemod.h> @@ -44,8 +43,8 @@ TileUI::TileUI(Tile* t, QWidget* parent) : QMetaObject::connectSlotsByName(this); setObjects(tile, tile_mod); connect(this, SIGNAL(changed(bool)), boxButtons, SLOT(setDisabled(bool))); - varAccessibility->addItems(DirectionStr.mid(0, 4)); - varHMType->addItems(HMStr); + varAccessibility->addItems(Pokemod::DirectionStr.mid(0, Pokemod::D_End)); + varHMType->addItems(Pokemod::HMStr); for (int i = 0; i < tile->getPokemod()->getTileCount(); ++i) { const Tile* tl = tile->getPokemod()->getTile(i); @@ -56,7 +55,7 @@ TileUI::TileUI(Tile* t, QWidget* parent) : } } varForce->addItems(Tile::ForceStr); - varDirection->addItems(DirectionStr.mid(0, 4)); + varDirection->addItems(Pokemod::DirectionStr.mid(0, Pokemod::D_End)); setGui(); } @@ -76,7 +75,7 @@ void TileUI::setGui() { BugCatcher::report(e); } - for (unsigned i = 0; i < D_End; ++i) + for (int i = 0; i < varAccessibility->count(); ++i) varAccessibility->item(i)->setSelected(tile_mod->getFrom(i)); varWildNum->setValue(tile_mod->getWildChance().getNum()); varWildDenom->setValue(tile_mod->getWildChance().getDenom()); @@ -85,7 +84,7 @@ void TileUI::setGui() boxHMs->setChecked((tile_mod->getHMType() == -1) ? Qt::Unchecked : Qt::Checked); varHMType->setCurrentIndex(tile_mod->getHMType()); varHMUnder->setCurrentIndex(varHMUnder->findData(tile_mod->getUnder())); - varHMUnder->setEnabled((tile_mod->getHMType() == HM_Whirlpool) || (tile_mod->getHMType() == HM_Cut) || (tile_mod->getHMType() == HM_RockSmash)); + varHMUnder->setEnabled((tile_mod->getHMType() == Pokemod::HM_Whirlpool) || (tile_mod->getHMType() == Pokemod::HM_Cut) || (tile_mod->getHMType() == Pokemod::HM_RockSmash)); boxForces->setChecked((tile_mod->getForceType() == -1) ? Qt::Unchecked : Qt::Checked); varForce->setCurrentIndex(tile_mod->getForceType()); varDirection->setCurrentIndex(tile_mod->getForceDirection()); |