From fa85318e91ea9bbe4638092767b3b8e0ea64f57c Mon Sep 17 00:00:00 2001 From: Ben Boeckel Date: Wed, 21 May 2008 17:22:27 +0000 Subject: [FIX] Classes in pokemod will no longer emit a changed signal if not actually changed [FIX] Logic error with checking to see if certain GUI elements need resetting [FIX] Using activated rather than currentIndexChanged signals for combo boxes [FIX] Qt bugs now irrelevant git-svn-id: https://pokegen.svn.sourceforge.net/svnroot/pokegen/trunk@161 6ecfd1a5-f3ed-3746-8530-beee90d26b22 --- pokemod/Map.cpp | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) (limited to 'pokemod/Map.cpp') diff --git a/pokemod/Map.cpp b/pokemod/Map.cpp index 92cdb98e..d66552e6 100644 --- a/pokemod/Map.cpp +++ b/pokemod/Map.cpp @@ -152,19 +152,17 @@ QDomElement Map::save() const void Map::setName(const QString& name) { - m_name = name; - emit(changed()); + CHECK(name); } -void Map::setFlyWarp(const int warp) +void Map::setFlyWarp(const int flyWarp) { - if ((warp != INT_MAX) && (warpIndex(warp) == INT_MAX)) + if ((flyWarp != INT_MAX) && (warpIndex(flyWarp) == INT_MAX)) { - emit(error(bounds("warp"))); + emit(error(bounds("flyWarp"))); return; } - m_flyWarp = warp; - emit(changed()); + CHECK(flyWarp); } void Map::setType(const int type) @@ -174,8 +172,7 @@ void Map::setType(const int type) emit(error(bounds("type"))); return; } - m_type = type; - emit(changed()); + CHECK(type); } QString Map::name() const -- cgit