After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 690416 - Translated string still appears in English
Translated string still appears in English
Status: RESOLVED FIXED
Product: frogr
Classification: Other
Component: UI
master
Other Linux
: Normal major
: ---
Assigned To: frogr maintainers
frogr maintainers
Depends on:
Blocks:
 
 
Reported: 2012-12-18 13:49 UTC by Alexandre Franke
Modified: 2012-12-19 16:01 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Fix missing gettext call (1.93 KB, patch)
2012-12-18 14:17 UTC, Alexandre Franke
committed Details | Review

Description Alexandre Franke 2012-12-18 13:49:32 UTC
The "Enter verification code:" string in the authentification dialog always appears in English even though it's been translated and the rest of the program appears in the correct language.

See http://git.gnome.org/browse/frogr/plain/help/fr/figures/auth-dialog-step2.png?h=master for example.
Comment 1 Alexandre Franke 2012-12-18 13:55:31 UTC
http://developer.gnome.org/glib/stable/glib-I18N.html#N-:CAPS states that gettext should be called at runtime and it doesn't seem to be the case. The relevant code is the following (from src/frogr-auth-dialog.c line 164):

label = gtk_label_new (auth_txt);
Comment 2 Alexandre Franke 2012-12-18 14:05:06 UTC
Actually I don't understand why you use that auth_txt variable. Couldn't we just remove it altogether and chang the label creation line to the following?

label = gtk_label_new (_("Enter verification code:"));
Comment 3 Alexandre Franke 2012-12-18 14:17:51 UTC
Created attachment 231806 [details] [review]
Fix missing gettext call

The auth_txt string was displayed in the C locale regardless of the user's locale.
Also get rid of the useless variables and have the strings directly in the fonction calls.
Comment 4 Mario Sánchez Prada 2012-12-19 14:28:01 UTC
Review of attachment 231806 [details] [review]:

(In reply to comment #3)
> Created an attachment (id=231806) [details] [review]
> Fix missing gettext call
> 
> The auth_txt string was displayed in the C locale regardless of the user's
> locale.
> Also get rid of the useless variables and have the strings directly in the
> fonction calls.

Thanks for your patch. Actually I don't understand either why I was using those variables at all. Perhaps they were useful in some way some time ago but they are definitely useless right now. 

Please feel free to commit the patch when possible.
Comment 5 Alexandre Franke 2012-12-19 16:01:38 UTC
Attachment 231806 [details] pushed as 6f901ed - Fix missing gettext call