[CrOS MultiDevice] Make strings in OOBE setup translate.

The crbug.com/945632 pointed out that the MultiDevice setup OOBE UI
showed an unfortunate behavior in other languages: only one string on
the page translated [1].

It turned out there were a few different problems masking one another.
First, the start-setup-page element did not bind its translations to
I18nBehavior.locale, which is the standard mechanism for passing
location data in OOBE. Once that was fixed, it became clear that the
OOBE screen 'MultiDeviceSetupScreen' was not notifying any Multidevice
Polymer elements of locale updates so the I18nBehavior.locale bindings
were not receiving updates. Also, because the buttons and headings were
translated in ui_page_container_behavior.js, those translations had to
be bound to I18nBehavior.locale separately. I also moved those
translations to more visible locations and used the literal string IDs
instead of factoring out the string IDs and computing the translations
in the UiPageContainerBehavior in an effort to make the data flow more
transparent.

The next big issue was that the strings with placeholders were not
registered appropriately in OOBE localization. This difference didn't
become clear until the binding issue was resolved because there was no
visible difference in the behavior of the placeholder strings and the
other strings until that point. Also, because the registration
infrastructure in OOBE uses a totally different API, the placeholder
strings were translating correctly post OOBE, which added to the
confusion. See multidevice_setup_localized_strings_provider.cc for the
relevant change.

After this change, the start-setup-page translates strings correctly in
OOBE [2] (this is the only MultiDevice screen in the OOBE flow) and
post-OOBE [3] along with the password-page [4] and setup-succeeded-page
[5].

Once this change is merged into the current branch (i.e. the immediate
fire is out), we can simplify
multidevice_setup_localized_string_provider.cc by splitting up the
strings with placeholders into regular strings and concatenatng them
manually in HTML (see crbug.com/961841).

[1] https://screenshot.googleplex.com/w2tWTTZJkvj
[2] https://screenshot.googleplex.com/dGvFOTQozLH
[3] https://screenshot.googleplex.com/9GuB8bwkqS4
[4] https://screenshot.googleplex.com/QGZc9aaEdtE
[5] https://screenshot.googleplex.com/FCAWDNTTVn4

Bug: 945632
Change-Id: I141e925e70550b1e33b06aef25ed4f72a06d5988
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1591965
Commit-Queue: Jordy Greenblatt <jordynass@chromium.org>
Reviewed-by: Kyle Horimoto <khorimoto@chromium.org>
Reviewed-by: Alexander Alekseev <alemate@chromium.org>
Cr-Commit-Position: refs/heads/master@{#662029}
15 files changed