Author: mordante
Date: Thu Nov 1 20:55:03 2007
New Revision: 21392
URL: http://svn.gna.org/viewcvs/wesnoth?rev=21392&view=rev
Log:
Revert 21260 and add the proper fix for the resize bug,
partial fix for bug #10216.
Modified:
trunk/src/editor/map_manip.cpp
Modified: trunk/src/editor/map_manip.cpp
URL:
http://svn.gna.org/viewcvs/wesnoth/trunk/src/editor/map_manip.cpp?rev=21392&r1=21391&r2=21392&view=diff
==============================================================================
--- trunk/src/editor/map_manip.cpp (original)
+++ trunk/src/editor/map_manip.cpp Thu Nov 1 20:55:03 2007
@@ -155,12 +155,8 @@
void editormap::add_tiles_right(
const unsigned count, const t_translation::t_letter& filler)
{
- // We can no longer 'trust' the map stats so need to get the info from
- // the tiles_. After adding the size() will change so use a temp
variable.
- const size_t size = tiles_.size();
-
for(size_t x = 1; x <= count; ++x) {
- t_translation::t_list one_row(size);
+ t_translation::t_list one_row(tiles_[1].size());
for(size_t y = 0; y < tiles_[1].size(); ++y) {
one_row[y] =
filler != t_translation::NONE_TERRAIN ?
@@ -176,12 +172,8 @@
void editormap::add_tiles_left(
const unsigned count, const t_translation::t_letter& filler)
{
- // We can no longer 'trust' the map stats so need to get the info from
- // the tiles_. After adding the size() will change so use a temp
variable.
- const size_t size = tiles_.size();
-
for(size_t i = 1; i <= count; ++i) {
- t_translation::t_list one_row(size);
+ t_translation::t_list one_row(tiles_[1].size());
for(size_t y = 0; y < tiles_[1].size(); ++y) {
one_row[y] =
filler != t_translation::NONE_TERRAIN ?
_______________________________________________
Wesnoth-commits mailing list
[email protected]
https://mail.gna.org/listinfo/wesnoth-commits