← Back to team overview

widelands-dev team mailing list archive

[Merge] lp:~widelands-dev/widelands/fix_building_statistics into lp:widelands

 

GunChleoc has proposed merging lp:~widelands-dev/widelands/fix_building_statistics into lp:widelands.

Requested reviews:
  Widelands Developers (widelands-dev)

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/fix_building_statistics/+merge/238699

Two small string fixes:

- Fixed nonsense buffer in bulding statistics.
- Stringfix for loading screen text.
-- 
https://code.launchpad.net/~widelands-dev/widelands/fix_building_statistics/+merge/238699
Your team Widelands Developers is requested to review the proposed merge of lp:~widelands-dev/widelands/fix_building_statistics into lp:widelands.
=== modified file 'src/wui/building_statistics_menu.cc'
--- src/wui/building_statistics_menu.cc	2014-09-18 18:52:34 +0000
+++ src/wui/building_statistics_menu.cc	2014-10-17 11:14:32 +0000
@@ -437,7 +437,6 @@
 		}
 
 		//  add new Table Entry
-		char buffer[100];
 		te->set_picture
 			(Columns::Name, building.get_icon(), building.descname());
 
@@ -483,15 +482,17 @@
 			}
 		}
 
-		//  number of this buildings
-		te->set_string(Columns::Owned, (boost::format("%3u") % nr_owned).str()); //  space-pad for sort
+		//  number of these buildings
+		std::string owned_string = (boost::format("%3u") % nr_owned).str(); //  space-pad for sort
+		te->set_string(Columns::Owned, owned_string);
 		if (is_selected)
-			m_owned.set_text(buffer);
+			m_owned.set_text(owned_string);
 
-		//  number of currently builds
-		te->set_string(Columns::Build, (boost::format("%3u") % nr_build).str()); //  space-pad for sort
+		//  number of these buildings currently being built
+		std::string build_string =  (boost::format("%3u") % nr_build).str();  //  space-pad for sort
+		te->set_string(Columns::Build,build_string);
 		if (is_selected)
-			m_in_build.set_text(buffer);
+			m_in_build.set_text(build_string);
 	}
 
 	//  disable all buttons, if nothing to select

=== modified file 'txts/tips/barbarians.tip'
--- txts/tips/barbarians.tip	2014-03-05 18:47:03 +0000
+++ txts/tips/barbarians.tip	2014-10-17 11:14:32 +0000
@@ -3,7 +3,7 @@
 sec=7
 
 [Tip 2]
-text=_Keep an eye on your fishers. After fish resources are exhausted in their working area, they will stop to fish.
+text=_Keep an eye on your fishers. After fish resources are exhausted in their working area, they will stop fishing.
 sec=4
 
 [Tip 3]

=== modified file 'txts/tips/empire.tip'
--- txts/tips/empire.tip	2014-03-05 18:47:03 +0000
+++ txts/tips/empire.tip	2014-10-17 11:14:32 +0000
@@ -3,7 +3,7 @@
 sec=7
 
 [Tip 2]
-text=_Keep an eye on your fishers. After fish resources are exhausted in their working area, they will stop to fish.
+text=_Keep an eye on your fishers. After fish resources are exhausted in their working area, they will stop fishing.
 sec=4
 
 [Tip 3]


Follow ups