← Back to team overview

widelands-dev team mailing list archive

Re: [Merge] lp:~widelands-dev/widelands/translation_stats into lp:widelands

 


Diff comments:

> 
> === modified file 'src/ui_fsmenu/options.cc'
> --- src/ui_fsmenu/options.cc	2017-09-11 16:59:41 +0000
> +++ src/ui_fsmenu/options.cc	2017-10-24 19:19:16 +0000
> @@ -432,7 +421,8 @@
>  	language_dropdown_.add(_("Try system language"), "", nullptr, current_locale == "");
>  	language_dropdown_.add("English", "en", nullptr, current_locale == "en");
>  
> -	// Add translation directories to the list
> +	// Add translation directories to the list. We are using a container that will support std::sort
> +	// and that will avoid any eventual hash collisions on the sortname.

std::map is not a hashmap, but a tree map. So the ordering is guaranteed to be always exactly the same as using std::sort on a vector, given the same comparison function.

>  	std::vector<LanguageEntry> entries;
>  	std::string selected_locale;
>  


-- 
https://code.launchpad.net/~widelands-dev/widelands/translation_stats/+merge/332029
Your team Widelands Developers is subscribed to branch lp:~widelands-dev/widelands/translation_stats.


References