コード例 #1
0
    @Override
    public ComponentContainer getLayout() {
      VerticalLayout formLayout = new VerticalLayout();
      formLayout.setDefaultComponentAlignment(Alignment.TOP_CENTER);

      Label organizationHeader =
          new Label(AppContext.getMessage(ContactI18nEnum.SECTION_DESCRIPTION));
      organizationHeader.setStyleName(UIConstants.H2_STYLE2);
      formLayout.addComponent(organizationHeader);

      informationLayout = GridFormLayoutHelper.defaultFormLayoutHelper(2, 6);
      formLayout.addComponent(informationLayout.getLayout());

      addressLayout = GridFormLayoutHelper.defaultFormLayoutHelper(2, 6);
      Label addressHeader = new Label(AppContext.getMessage(ContactI18nEnum.SECTION_ADDRESS));
      addressHeader.setStyleName(UIConstants.H2_STYLE2);
      formLayout.addComponent(addressHeader);
      formLayout.addComponent(addressLayout.getLayout());
      formLayout.addComponent(buildButtonControls());
      return formLayout;
    }