Opened 12 years ago

Closed 12 years ago

#3100 closed defect (fixed)

Strings in dnd avatar need to be localized

Reported by: Adam Peller Owned by: Eugene Lazutkin
Priority: high Milestone: 0.9
Component: DnD Version: 0.9
Keywords: i18n Cc: owen, Adam Peller
Blocked By: Blocking:

Description

_generateText has some hard-coded English strings. Either we should try to avoid localized strings, or we'll need to add a nls/ directory with support.

Change History (17)

comment:1 Changed 12 years ago by Eugene Lazutkin

Owner: changed from Ben Lowery to bill

Makes sense. Who can do the localization work for it? Temporary assigning it to Bill.

comment:2 Changed 12 years ago by Eugene Lazutkin

Owner: changed from bill to Adam Peller

After discussion with Adam I reassign it temporarily to him.

comment:3 Changed 12 years ago by Eugene Lazutkin

Cc: elazutkin@… added

comment:4 Changed 12 years ago by Adam Peller

Component: DnDInternationalization
Keywords: i18n added

comment:5 Changed 12 years ago by Adam Peller

Eugene, can you remind me what our plan was for this? Did Owen's proposed UI resolve this?

comment:6 Changed 12 years ago by Eugene Lazutkin

He didn't propose anything yet. I doubt he had time to look at it.

comment:7 Changed 12 years ago by Adam Peller

Cc: Eugene Lazutkin Adam Peller added; elazutkin@… removed
Owner: changed from Adam Peller to owen

Owen, can you take a look at this and see if you can suggest a language-neutral way of expressing what we need, or simplifying the model? If we need strings, that's ok, but I'd rather avoid them. Having to rely on plural, though, is particularly troublesome.

comment:8 Changed 12 years ago by bill

Milestone: 0.91.0

comment:9 Changed 12 years ago by Adam Peller

one more plea... Owen, any way we can look at this for 0.9?

comment:10 Changed 12 years ago by Adam Peller

Cc: owen added; Adam Peller removed
Milestone: 1.00.9
Owner: changed from owen to Adam Peller

This is the last string in the codebase that I know of. It would be real nice to ship with a clean slate for 0.9.

Three quick resolutions:

  • Change wording to something like "copying/moving count: ${0}" and localize the string. This is the most costly, given that core doesn't typically use resources, and I think it overcomplicates the UI, but just MHO.
  • Have some pluggable mechanism so the user can easily add behavior like this, localized or not, but leave the default as something simple, like just the number (perhaps in 1.0 we'll use a cursor graphic or something to indicate copy/move state)
  • Just get rid of the string altogether. Use a number or nothing at all.

My preference is in the reverse order. Eugene, what do you think?

comment:11 Changed 12 years ago by Eugene Lazutkin

Cc: Adam Peller added; Eugene Lazutkin removed
Owner: changed from Adam Peller to Eugene Lazutkin
Status: newassigned

The Avatar._generateText() method was specifically created to keep the text in one place, and to make it easily replaceable. So my inclination is to go with #2. #3 is not the optimum choice because the default implementation of the avatar cannot have more than 5 elements visible --- this is the reason why it has the number: it gives you a feedback that you are dragging more than 5 visible elements.

Let me consult with the UI guy on how to handle it for now, and I'll try to close the ticket before 0.9 ships.

comment:12 Changed 12 years ago by Eugene Lazutkin

Component: InternationalizationDnD

Most probably I'll go with the solution shown in flickr_viewer.html demo (small icon to indicate the operation). So I will need to add 4 small images and a handful of CSS rules. All text (safe for the number of items) will be removed. I plan to put these images in dojo/resources/ next to dojo.css, which will have required rules added. If somebody doesn't include dojo.css (or a copy of rules in their CSS files), the user will see just a number without any other visual hints.

Adam, Owen --- is it acceptable?

comment:13 Changed 12 years ago by Eugene Lazutkin

(In [10231]) Replacing images with a new normalized set. Refs #3100.

comment:14 Changed 12 years ago by Eugene Lazutkin

(In [10234]) Created new dnd.css, images moved to resources, all DnD-related tests and demos are updated, Flickr Viewer is tweaked somewhat. Refs #3100.

comment:15 Changed 12 years ago by Eugene Lazutkin

(In [10235]) More tweaking to Flickr Viewer, removed gif files. Refs #3100.

comment:16 Changed 12 years ago by Eugene Lazutkin

(In [10236]) Removed English text from the default Avatar. Added an example on how to override the text using a custom code to Flickr Viewer. Refs #3100.

comment:17 Changed 12 years ago by Eugene Lazutkin

Resolution: fixed
Status: assignedclosed
Note: See TracTickets for help on using tickets.