Author: sapient Date: Sun Jun 17 19:14:00 2007 New Revision: 18335 URL: http://svn.gna.org/viewcvs/wesnoth?rev=18335&view=rev Log: http://www.wesnoth.org/wiki/CodingStandards#Do_not_use_C-style_casts
Modified: trunk/src/game_config.cpp trunk/src/game_config.hpp trunk/src/multiplayer_ui.cpp Modified: trunk/src/game_config.cpp URL: http://svn.gna.org/viewcvs/wesnoth/trunk/src/game_config.cpp?rev=18335&r1=18334&r2=18335&view=diff ============================================================================== --- trunk/src/game_config.cpp (original) +++ trunk/src/game_config.cpp Sun Jun 17 19:14:00 2007 @@ -33,7 +33,7 @@ int rest_heal_amount= 2; int recall_cost = 20; int kill_experience = 8; - int lobby_refresh = 2000; + unsigned lobby_refresh = 2000; const std::string version = VERSION; #ifdef SVNREV const std::string svnrev = SVNREV; @@ -122,7 +122,7 @@ rest_heal_amount = atoi(v["rest_heal_amount"].c_str()); recall_cost = atoi(v["recall_cost"].c_str()); kill_experience = atoi(v["kill_experience"].c_str()); - lobby_refresh = atoi(v["lobby_refresh"].c_str()); + lobby_refresh = static_cast<unsigned>(atoi(v["lobby_refresh"].c_str())); game_icon = v["icon"]; game_title = v["title"]; Modified: trunk/src/game_config.hpp URL: http://svn.gna.org/viewcvs/wesnoth/trunk/src/game_config.hpp?rev=18335&r1=18334&r2=18335&view=diff ============================================================================== --- trunk/src/game_config.hpp (original) +++ trunk/src/game_config.hpp Sun Jun 17 19:14:00 2007 @@ -30,7 +30,7 @@ extern int rest_heal_amount; extern int recall_cost; extern int kill_experience; - extern int lobby_refresh; + extern unsigned lobby_refresh; extern const std::string version; #ifdef SVNREV extern const std::string svnrev; Modified: trunk/src/multiplayer_ui.cpp URL: http://svn.gna.org/viewcvs/wesnoth/trunk/src/multiplayer_ui.cpp?rev=18335&r1=18334&r2=18335&view=diff ============================================================================== --- trunk/src/multiplayer_ui.cpp (original) +++ trunk/src/multiplayer_ui.cpp Sun Jun 17 19:14:00 2007 @@ -254,7 +254,7 @@ } //apply diffs at a set interval - if(gamelist_refresh_ && SDL_GetTicks() - lobby_clock_ > (unsigned)game_config::lobby_refresh) + if(gamelist_refresh_ && SDL_GetTicks() - lobby_clock_ > game_config::lobby_refresh) { const cursor::setter cursor_setter(cursor::WAIT); gamelist_updated(false); _______________________________________________ Wesnoth-commits mailing list Wesnoth-commits@gna.org https://mail.gna.org/listinfo/wesnoth-commits