Change in ovirt-engine[master]: webadmin: "No message" is displayed in Japanese environment

tjelinek at redhat.com tjelinek at redhat.com
Mon Dec 17 12:11:45 UTC 2012


Tomas Jelinek has submitted this change and it was merged.

Change subject: webadmin: "No message" is displayed in Japanese environment
......................................................................


webadmin: "No message" is displayed in Japanese environment

New/Edit VM dialog -> fill a japanese chars into the description
field. An error dialog with message "No message" will be displayed.

The problem was, that the ErrorTranslator expected, that when a message
is in form: "$AAA b" is a variable $AAA with value "b". Than it expected
that the ${AAA} in other messages can be replaced by "b". The problem
was, that the decision, if the specific message is a variable declaration
or a message was decided in a following way:
- if the string starts with "$" character, than it is a variable declaration
- it is a message otherwise

The problem with this is, that when a message looks like "${AAA} b"
than it is considered to be a variable declaration, even it is a message
with reference to the declaration.

Fixed by enriching this decision if somethin is a variable declaratition to
the following:
- if the string starts with "$" but it is does not start with something like
"${some string}" it is a variable
- it is a message otherwise

Change-Id: I04b32be4cf4c05873bcf9643dd5b9acb3695a54a
Signed-off-by: Tomas Jelinek <tjelinek at redhat.com>
---
M frontend/webadmin/modules/frontend/src/main/java/org/ovirt/engine/ui/frontend/ErrorTranslator.java
A frontend/webadmin/modules/frontend/src/test/java/org/ovirt/engine/ui/frontend/ErrorTranslatorTest.java
2 files changed, 47 insertions(+), 2 deletions(-)

Approvals:
  Tomas Jelinek: Verified; Looks good to me, approved


--
To view, visit http://gerrit.ovirt.org/9818
To unsubscribe, visit http://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I04b32be4cf4c05873bcf9643dd5b9acb3695a54a
Gerrit-PatchSet: 3
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Tomas Jelinek <tjelinek at redhat.com>
Gerrit-Reviewer: Daniel Erez <derez at redhat.com>
Gerrit-Reviewer: Einav Cohen <ecohen at redhat.com>
Gerrit-Reviewer: Gilad Chaplik <gchaplik at redhat.com>
Gerrit-Reviewer: Tomas Jelinek <tjelinek at redhat.com>



More information about the Engine-commits mailing list