[wesnoth-commits] [wesnoth/wesnoth] dbac6e: i18n: Forcefully pull gettext.hpp into formula/str...
GitHub
noreply at github.com
Fri Mar 23 06:53:46 UTC 2018
Branch: refs/heads/1.14
Home: https://github.com/wesnoth/wesnoth
Commit: dbac6e4e08f304f113538cd637868fb4544df71a
https://github.com/wesnoth/wesnoth/commit/dbac6e4e08f304f113538cd637868fb4544df71a
Author: Iris Morelle <shadowm at wesnoth.org>
Date: 2018-03-23 (Fri, 23 Mar 2018)
Changed paths:
M src/formula/string_utils.hpp
Log Message:
-----------
i18n: Forcefully pull gettext.hpp into formula/string_utils.hpp
There are cases (deprecation.cpp for one) where string_utils.hpp is
included first, which causes the VGETTEXT/VNGETTEXT definition to use
the textdomain-less (a.k.a. forced wesnoth-lib textdomain) overloads of
vgettext() and vngettext(), because GETTEXT_DOMAIN has not yet been
defined by anything. This again results in strings being looked up in
catalogues where xgettext is not adding them.
This is a companion for PR #2711 I should've noticed sooner. Without it,
there were still cases where interpolated strings would not be
translated due to vgettext() using the wrong textdomain for them.
I ran a quick scan on the codebase to make sure there aren't any files
including formula/string_utils.hpp before defining their own
GETTEXT_DOMAIN instead of the gettext.hpp default.
Commit: 26b327485d3a79b9ace043b6fd4c575527dc321d
https://github.com/wesnoth/wesnoth/commit/26b327485d3a79b9ace043b6fd4c575527dc321d
Author: Iris Morelle <shadowm at wesnoth.org>
Date: 2018-03-23 (Fri, 23 Mar 2018)
Changed paths:
M src/formula/string_utils.hpp
Log Message:
-----------
i18n: Make VGETTEXT()/VNGETTEXT() always require a GETTEXT_DOMAIN to be defined
This drops a preprocessor conditional branch that is dead code now that
the file pulls gettext.hpp and the GETTEXT_DOMAIN defaults with it.
See also PR #2711.
Compare: https://github.com/wesnoth/wesnoth/compare/96032f978c43...26b327485d3a
More information about the Commits
mailing list