Welcome, Guest! Log In | Create Account

Ticket #100 (closed defect: fixed)

Opened 12 months ago

Last modified 8 months ago

Show strings from dialogs (AHAH) in l10n_client

Reported by: andy_st Owned by: andy_st
Priority: major Milestone: 3.0 Beta 2
Version: Keywords: l10n
Cc:

Description

The l10n_client currently only shows all messages that are part of the generated HTTP response.

If the view loads additional components / dialogs / widgets via XHR, these additional messages are not shown in the l10n_client yet.

Change History

Changed 12 months ago by andy_st

Also make sure that these messages are localizable:

-Photo functions: rotate 90 degrees/delete this photo/set as cover etc
-flash uploader
-buttons: e.g. <add a comment>
-popup forms: e.g. edit photo/add an album to gallery

Changed 11 months ago by andy_st

Proposed solution:

Instead of recording all translate() calls during the HTTP request, annotate all messages with the message id:

E.g. in translation mode, translate("Hello world") returns "Hallo Welt<msgId:7865>" instead of "Hallo Welt"

Then, in JavaScript?, we can search the DOM for all Strings that match the pattern "<msgId:\d+>", load the corresponding message source / translation strings and display that data in the translation UI.

A button can be added to rescan the page for strings. This can be done after clicking a button/link which opens a dialog (which adds more strings to the DOM).

Changed 11 months ago by andy_st

  • keywords l10n added

Changed 9 months ago by andy_st

  • milestone changed from 3.0 Alpha 4 to 3.0 Beta 1

Changed 9 months ago by andy_st

The new plan is to provide an additional standalone page which lists ALL translation messages of the whole Gallery. A single catch-all page to translate strings that are hard to discover (e.g. only displayed in dialogs, only displayed to guests, etc.).

Changed 9 months ago by bharat

  • milestone changed from 3.0 Beta 1 to 3.0 Beta 2

Changed 8 months ago by andy_st

  • status changed from new to closed
  • resolution set to fixed

This is now in git head
(http://github.com/gallery/gallery3/commit/be226b9baa8ce21431e35c32277fda2e8c94a216).

To see it
1. "get updates" in the language admin screen, to ensure that the DB has indexed all source files
2. click "start translating"
3. in the translation UI, next to "Page Text" click on "Show all" (the link color is unfortunate right now)

Note: See TracTickets for help on using tickets.