/** {@inheritDoc} */
  @Override
  public void setLanguage(final DatePickerLanguage language) {
    this.language = language;

    // Inject the JS for the language
    if (language.getJs() != null) {
      ScriptInjector.fromString(language.getJs().getText())
          .setWindow(ScriptInjector.TOP_WINDOW)
          .inject();
    }
  }
  protected void configure(final Widget w, final Widget container) {
    w.getElement().setAttribute("data-date-format", format);

    // If configuring not for the first time, datepicker must be removed first.
    this.remove(w.getElement());

    configure(
        w.getElement(),
        container.getElement(),
        format,
        weekStart.getValue(),
        toDaysOfWeekDisabledString(daysOfWeekDisabled),
        autoClose,
        startView.getValue(),
        minView.getValue(),
        showTodayButton,
        highlightToday,
        keyboardNavigation,
        forceParse,
        viewSelect.getValue(),
        language.getCode(),
        position.getPosition());
  }