docs: public void updateButtonVisibility(boolean hasAddButton, boolean hasRemoveButton, boolean hasSortButtons) {
  
          if (hasAddButton && m_isChoice) {
              m_attributeChoice.getElement().getStyle().clearDisplay();
          } else {
              m_attributeChoice.getElement().getStyle().setDisplay(Display.NONE);
          }
          if (hasAddButton && !m_isChoice) {
              m_addButton.getElement().getStyle().clearDisplay();
          } else {
              m_addButton.getElement().getStyle().setDisplay(Display.NONE);
          }
  
          if (hasRemoveButton) {
              m_removeButton.getElement().getStyle().clearDisplay();
          } else {
              m_removeButton.getElement().getStyle().setDisplay(Display.NONE);
          }
          if (hasSortButtons && (getValueIndex() != 0)) {
              m_upButton.getElement().getStyle().clearDisplay();
          } else {
              m_upButton.getElement().getStyle().setDisplay(Display.NONE);
          }
          if (hasSortButtons && (getElement().getNextSibling() != null)) {
              m_downButton.getElement().getStyle().clearDisplay();
          } else {
              m_downButton.getElement().getStyle().setDisplay(Display.NONE);
          }
          if (hasSortButtons) {
              m_moveButton.addStyleName(I_CmsLayoutBundle.INSTANCE.form().moveHandle());
              if (CmsEditorBase.hasDictionary()) {
                  m_moveButton.setTitle(CmsEditorBase.getMessageForKey(CmsEditorBase.GUI_VIEW_MOVE_1, m_label));
              }
          } else {
              m_moveButton.setTitle("");
              m_moveButton.removeStyleName(I_CmsLayoutBundle.INSTANCE.form().moveHandle());
          }
          m_dragEnabled = hasSortButtons;
          if (!hasAddButton && !hasRemoveButton && !hasSortButtons) {
              // hide the button bar if no button is visible
              m_buttonBar.getElement().getStyle().setDisplay(Display.NONE);
          } else {
              // show the button bar
              m_buttonBar.getElement().getStyle().clearDisplay();
              if (hasSortButtons || (hasAddButton && hasRemoveButton)) {
                  // set multi button mode
                  m_buttonBar.addStyleName(formCss().multiButtonBar());
                  m_moveButton.getElement().getStyle().clearDisplay();
              } else {
                  m_moveButton.getElement().getStyle().setDisplay(Display.NONE);
                  m_buttonBar.removeStyleName(formCss().multiButtonBar());
              }
          }
      }