List of usage examples for com.vaadin.ui Alignment TOP_LEFT
Alignment TOP_LEFT
To view the source code for com.vaadin.ui Alignment TOP_LEFT.
Click Source Link
From source file:com.esofthead.mycollab.module.project.view.milestone.MilestoneFormLayoutFactory.java
License:Open Source License
@Override public Layout getLayout() { final VerticalLayout layout = new VerticalLayout(); this.informationLayout = new GridFormLayoutHelper(2, 5, "100%", "145px", Alignment.TOP_LEFT); this.informationLayout.getLayout().setWidth("100%"); this.informationLayout.getLayout().addStyleName("colored-gridlayout"); this.informationLayout.getLayout().setMargin(false); layout.addComponent(this.informationLayout.getLayout()); layout.setComponentAlignment(this.informationLayout.getLayout(), Alignment.BOTTOM_CENTER); return layout; }
From source file:com.esofthead.mycollab.module.project.view.page.PageFormLayoutFactory.java
License:Open Source License
@Override public ComponentContainer getLayout() { final VerticalLayout layout = new VerticalLayout(); this.informationLayout = new GridFormLayoutHelper(2, 3, "100%", "167px", Alignment.TOP_LEFT); this.informationLayout.getLayout().setWidth("100%"); this.informationLayout.getLayout().setMargin(false); this.informationLayout.getLayout().addStyleName("colored-gridlayout"); layout.addComponent(this.informationLayout.getLayout()); layout.setComponentAlignment(this.informationLayout.getLayout(), Alignment.BOTTOM_CENTER); return layout; }
From source file:com.esofthead.mycollab.module.project.view.ProjectInformationLayout.java
License:Open Source License
@Override public void attachField(final Object propertyId, final Field<?> field) { if (propertyId.equals("homepage")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_HOME_PAGE), 0, 0, Alignment.TOP_LEFT); } else if (propertyId.equals("projectstatus")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_STATUS), 1, 0, Alignment.TOP_LEFT);/* www . jav a 2s.c o m*/ } else if (propertyId.equals("planstartdate")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_PLAN_START_DATE), 0, 1, Alignment.TOP_LEFT); } else if (propertyId.equals("currencyid")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_CURRENCY), 1, 1, Alignment.TOP_LEFT); } else if (propertyId.equals("planenddate")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_PLAN_END_DATE), 0, 2, Alignment.TOP_LEFT); } else if (propertyId.equals("defaultbillingrate")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_BILLING_RATE), 1, 2, Alignment.TOP_LEFT); } else if (propertyId.equals("actualstartdate")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_ACTUAL_START_DATE), 0, 3, Alignment.TOP_LEFT); } else if (propertyId.equals("targetbudget")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_TARGET_BUDGET), 1, 3, Alignment.TOP_LEFT); } else if (propertyId.equals("actualenddate")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_ACTUAL_END_DATE), 0, 4, Alignment.TOP_LEFT); } else if (propertyId.equals("actualbudget")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_ACTUAL_BUDGET), 1, 4, Alignment.TOP_LEFT); } else if (propertyId.equals("totalBillableHours")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_BILLABLE_HOURS), 0, 5, Alignment.TOP_LEFT); } else if (propertyId.equals("totalNonBillableHours")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(ProjectI18nEnum.FORM_NON_BILLABLE_HOURS), 1, 5, Alignment.TOP_LEFT); } else if (propertyId.equals("description")) { this.moreInfoLayout.addComponent(field, AppContext.getMessage(GenericI18Enum.FORM_DESCRIPTION), 0, 6, 2, "100%", Alignment.TOP_LEFT); } }
From source file:com.esofthead.mycollab.module.project.view.ProjectInformationLayout.java
License:Open Source License
@Override public ComponentContainer getLayout() { this.moreInfoLayout = new GridFormLayoutHelper(2, 7, "100%", "167px", Alignment.TOP_LEFT); this.moreInfoLayout.getLayout().setWidth("100%"); this.moreInfoLayout.getLayout().setMargin(false); this.moreInfoLayout.getLayout().addStyleName("colored-gridlayout"); return this.moreInfoLayout.getLayout(); }
From source file:com.esofthead.mycollab.module.project.view.settings.ProjectMemberFormLayoutFactory.java
License:Open Source License
@Override public ComponentContainer getLayout() { final VerticalLayout layout = new VerticalLayout(); final Label organizationHeader = new Label( AppContext.getMessage(ProjectMemberI18nEnum.FORM_INFORMATION_SECTION)); organizationHeader.setStyleName("h2"); layout.addComponent(organizationHeader); this.informationLayout = new GridFormLayoutHelper(1, 2, "100%", "167px", Alignment.TOP_LEFT); this.informationLayout.getLayout().setWidth("100%"); this.informationLayout.getLayout().setMargin(false); this.informationLayout.getLayout().addStyleName("colored-gridlayout"); layout.addComponent(this.informationLayout.getLayout()); return layout; }
From source file:com.esofthead.mycollab.module.project.view.settings.ProjectMemberInviteViewImpl.java
License:Open Source License
private void initContent() { this.removeAllComponents(); this.roleComboBox = new ProjectRoleComboBox(); this.roleComboBox.addValueChangeListener(new ValueChangeListener() { private static final long serialVersionUID = 1L; @Override//from w ww .ja v a2s .c o m public void valueChange(ValueChangeEvent event) { Integer roleId = (Integer) roleComboBox.getValue(); displayRolePermission(roleId); } }); final AddViewLayout userAddLayout = new AddViewLayout( AppContext.getMessage(ProjectMemberI18nEnum.FORM_INVITE_MEMBERS), FontAwesome.USER); userAddLayout.addHeaderRight(createButtonControls()); GridFormLayoutHelper informationLayout = new GridFormLayoutHelper(1, 3, "100%", "167px", Alignment.TOP_LEFT); informationLayout.getLayout().setWidth("100%"); informationLayout.getLayout().setMargin(false); informationLayout.getLayout().addStyleName("colored-gridlayout"); final MHorizontalLayout lo = new MHorizontalLayout(); InviteUserTokenField inviteUserTokenField = new InviteUserTokenField(lo); informationLayout.addComponent(inviteUserTokenField, AppContext.getMessage(ProjectMemberI18nEnum.FORM_INVITEES_EMAIL), 0, 0); informationLayout.addComponent(roleComboBox, AppContext.getMessage(ProjectMemberI18nEnum.FORM_ROLE), 0, 1); messageArea = new TextArea(); messageArea.setValue(AppContext.getMessage(ProjectMemberI18nEnum.MSG_DEFAULT_INVITATION_COMMENT)); informationLayout.addComponent(messageArea, AppContext.getMessage(ProjectMemberI18nEnum.FORM_MESSAGE), 0, 2); userAddLayout.addBody(informationLayout.getLayout()); userAddLayout.addBottomControls(createBottomPanel()); this.addComponent(userAddLayout); }
From source file:com.esofthead.mycollab.module.project.view.settings.ProjectMemberInviteViewImpl.java
License:Open Source License
private Layout createBottomPanel() { VerticalLayout permissionsPanel = new VerticalLayout(); final Label organizationHeader = new Label(AppContext.getMessage(ProjectRoleI18nEnum.SECTION_PERMISSIONS)); organizationHeader.setStyleName("h2"); permissionsPanel.addComponent(organizationHeader); projectFormHelper = new GridFormLayoutHelper(2, ProjectRolePermissionCollections.PROJECT_PERMISSIONS.length, "100%", "167px", Alignment.TOP_LEFT); projectFormHelper.getLayout().setWidth("100%"); projectFormHelper.getLayout().setMargin(false); projectFormHelper.getLayout().addStyleName("colored-gridlayout"); permissionsPanel.addComponent(projectFormHelper.getLayout()); roleId = (Integer) roleComboBox.getValue(); displayRolePermission(roleId);//from ww w . java2 s . c om return permissionsPanel; }
From source file:com.esofthead.mycollab.module.project.view.settings.ProjectRoleAddViewImpl.java
License:Open Source License
@Override protected ComponentContainer createBottomPanel() { final VerticalLayout permissionsPanel = new VerticalLayout(); final Label organizationHeader = new Label(AppContext.getMessage(ProjectRoleI18nEnum.SECTION_PERMISSIONS)); organizationHeader.setStyleName("h2"); permissionsPanel.addComponent(organizationHeader); PermissionMap perMap;//from ww w. ja va2s. c o m if (beanItem instanceof SimpleProjectRole) { perMap = ((SimpleProjectRole) beanItem).getPermissionMap(); } else { perMap = new PermissionMap(); } final GridFormLayoutHelper permissionFormHelper = new GridFormLayoutHelper(2, ProjectRolePermissionCollections.PROJECT_PERMISSIONS.length, "100%", "167px", Alignment.TOP_LEFT); for (int i = 0; i < ProjectRolePermissionCollections.PROJECT_PERMISSIONS.length; i++) { final String permissionPath = ProjectRolePermissionCollections.PROJECT_PERMISSIONS[i]; final AccessPermissionComboBox permissionBox = new AccessPermissionComboBox(); final Integer flag = perMap.getPermissionFlag(permissionPath); permissionBox.setValue(flag); permissionControlsMap.put(permissionPath, permissionBox); permissionFormHelper.addComponent(permissionBox, AppContext.getMessage(RolePermissionI18nEnum.valueOf(permissionPath)), 0, i); } permissionFormHelper.getLayout().setWidth("100%"); permissionFormHelper.getLayout().setMargin(false); permissionFormHelper.getLayout().addStyleName("colored-gridlayout"); permissionsPanel.addComponent(permissionFormHelper.getLayout()); return permissionsPanel; }
From source file:com.esofthead.mycollab.module.project.view.settings.ProjectRoleFormLayoutFactory.java
License:Open Source License
@Override public ComponentContainer getLayout() { final VerticalLayout layout = new VerticalLayout(); final Label organizationHeader = new Label("Role Information"); organizationHeader.setStyleName("h2"); layout.addComponent(organizationHeader); this.informationLayout = new GridFormLayoutHelper(2, 2, "100%", "167px", Alignment.TOP_LEFT); this.informationLayout.getLayout().setWidth("100%"); this.informationLayout.getLayout().setMargin(false); this.informationLayout.getLayout().addStyleName("colored-gridlayout"); layout.addComponent(this.informationLayout.getLayout()); return layout; }
From source file:com.esofthead.mycollab.module.project.view.settings.ProjectRoleReadViewImpl.java
License:Open Source License
protected ComponentContainer createBottomPanel() { VerticalLayout permissionsPanel = new VerticalLayout(); final Label organizationHeader = new Label(AppContext.getMessage(ProjectRoleI18nEnum.SECTION_PERMISSIONS)); organizationHeader.setStyleName("h2"); permissionsPanel.addComponent(organizationHeader); projectFormHelper = new GridFormLayoutHelper(2, ProjectRolePermissionCollections.PROJECT_PERMISSIONS.length, "100%", "167px", Alignment.TOP_LEFT); projectFormHelper.getLayout().setWidth("100%"); projectFormHelper.getLayout().setMargin(false); projectFormHelper.getLayout().addStyleName("colored-gridlayout"); permissionsPanel.addComponent(projectFormHelper.getLayout()); return permissionsPanel; }