List of usage examples for com.vaadin.server FontAwesome USER_MD
FontAwesome USER_MD
To view the source code for com.vaadin.server FontAwesome USER_MD.
Click Source Link
From source file:com.etest.view.systemadministration.faculty.FacultyFormWindow.java
FormLayout buildForms() { FormLayout form = new FormLayout(); form.setWidth("100%"); form.setSpacing(true);/*w ww . j a va2s . c o m*/ form.setMargin(true); firstname.setWidth("100%"); firstname.setIcon(FontAwesome.INFO); firstname.setRequired(true); firstname.addStyleName(ValoTheme.TEXTFIELD_SMALL); form.addComponent(firstname); middlename.setWidth("100%"); middlename.setIcon(FontAwesome.INFO); middlename.setRequired(true); middlename.addStyleName(ValoTheme.TEXTFIELD_SMALL); form.addComponent(middlename); lastname.setWidth("100%"); lastname.setIcon(FontAwesome.INFO); lastname.setRequired(true); lastname.addStyleName(ValoTheme.TEXTFIELD_SMALL); form.addComponent(lastname); userType.setCaption("User Type: "); userType.setIcon(FontAwesome.USER_MD); userType.setRequired(true); form.addComponent(userType); username.setWidth("100%"); username.setIcon(FontAwesome.USER); username.setRequired(true); username.addStyleName(ValoTheme.TEXTFIELD_SMALL); form.addComponent(username); password1.setWidth("100%"); password1.setIcon(FontAwesome.CODE); password1.setRequired(true); password1.addStyleName(ValoTheme.TEXTFIELD_SMALL); form.addComponent(password1); password2.setWidth("100%"); password2.setIcon(FontAwesome.CODE); password2.setRequired(true); password2.addStyleName(ValoTheme.TEXTFIELD_SMALL); form.addComponent(password2); facultyBtn.setCaption(getButtonCaption()); facultyBtn.setWidth("100%"); facultyBtn.addStyleName(ValoTheme.BUTTON_PRIMARY); facultyBtn.addStyleName(ValoTheme.BUTTON_SMALL); facultyBtn.addClickListener(buttonClickListener); form.addComponent(facultyBtn); if (getFacultyId() != 0) { Users u = fs.getFacultyInfoById(getFacultyId()); firstname.setValue(u.getFirstname()); middlename.setValue(u.getMiddlename()); lastname.setValue(u.getLastname()); username.setValue(u.getUsername_()); userType.setValue(CommonVariableMap.getFacultyUserType(u.getUserType())); password1.setValue(u.getPassword_()); password2.setValue(u.getPassword_()); } return form; }
From source file:com.mycollab.module.project.view.settings.UserSettingViewImpl.java
License:Open Source License
private void buildComponents() { userPresenter = PresenterResolver.getPresenter(ProjectUserPresenter.class); myProjectTab.addTab(userPresenter.getView(), UserUIContext.getMessage(ProjectMemberI18nEnum.LIST), FontAwesome.USERS);//from w w w.j a v a 2 s.c o m rolePresenter = PresenterResolver.getPresenter(ProjectRolePresenter.class); myProjectTab.addTab(rolePresenter.getView(), UserUIContext.getMessage(ProjectRoleI18nEnum.LIST), FontAwesome.USER_MD); componentPresenter = PresenterResolver.getPresenter(ComponentPresenter.class); myProjectTab.addTab(componentPresenter.getView(), UserUIContext.getMessage(ComponentI18nEnum.LIST), ProjectAssetsManager.getAsset(ProjectTypeConstants.BUG_COMPONENT)); versionPresenter = PresenterResolver.getPresenter(VersionPresenter.class); myProjectTab.addTab(versionPresenter.getView(), UserUIContext.getMessage(VersionI18nEnum.LIST), ProjectAssetsManager.getAsset(ProjectTypeConstants.BUG_VERSION)); settingPresenter = PresenterResolver.getPresenter(ProjectSettingPresenter.class); myProjectTab.addTab(settingPresenter.getView(), UserUIContext.getMessage(ProjectCommonI18nEnum.VIEW_SETTINGS), FontAwesome.COG); myProjectTab.addSelectedTabChangeListener(new SelectedTabChangeListener() { private static final long serialVersionUID = 1L; @Override public void selectedTabChange(SelectedTabChangeEvent event) { Tab tab = ((TabSheetDecorator) event.getTabSheet()).getSelectedTabInfo(); String caption = tab.getCaption(); SimpleProject project = CurrentProjectVariables.getProject(); if (UserUIContext.getMessage(ProjectMemberI18nEnum.LIST).equals(caption)) { ProjectMemberSearchCriteria criteria = new ProjectMemberSearchCriteria(); criteria.setProjectId(new NumberSearchField(project.getId())); criteria.setStatuses(new SetSearchField<>(ProjectMemberStatusConstants.ACTIVE, ProjectMemberStatusConstants.NOT_ACCESS_YET)); userPresenter.go(UserSettingViewImpl.this, new ScreenData.Search<>(criteria)); } else if (UserUIContext.getMessage(ProjectRoleI18nEnum.LIST).equals(caption)) { ProjectRoleSearchCriteria criteria = new ProjectRoleSearchCriteria(); criteria.setProjectId(new NumberSearchField(project.getId())); rolePresenter.go(UserSettingViewImpl.this, new ProjectRoleScreenData.Search(criteria)); } else if (UserUIContext.getMessage(ProjectCommonI18nEnum.VIEW_SETTINGS).equals(caption)) { settingPresenter.go(UserSettingViewImpl.this, null); } else if (UserUIContext.getMessage(ComponentI18nEnum.LIST).equals(caption)) { componentPresenter.go(UserSettingViewImpl.this, null); } else if (UserUIContext.getMessage(VersionI18nEnum.LIST).equals(caption)) { versionPresenter.go(UserSettingViewImpl.this, null); } } }); }