Uploaded image for project: 'Wicket'
  1. Wicket
  2. WICKET-1982

Palette's AbstractOptions should localize values as AbstractChoice does

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 1.4-RC1
    • 1.4-RC2
    • wicket
    • None

    Description

      Palette's AbstractOptions uses the id and value for localization:

      value = getLocalizer().getString(id + "." + value, this, value);

      This requires me to duplicate parts of the keys in my property file. If I'm using a ChoiceRenderer("name", "name") for a hypothetical class B it looks like:
      Bar.A.Bar.A = Aaaa
      Bar.B.Bar.B = Bbbb
      Bar.C.Bar.C = Cccc

      AbstractOptions should be aligned with how AbstractChoice works, localizing the displayValue only without the id:

      display = getLocalizer().getString(displayValue, this, displayValue);

      Attachments

        Issue Links

          Activity

            People

              ivaynberg Igor Vaynberg
              svenmeier Sven Meier
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: