List of usage examples for com.vaadin.ui GridLayout GridLayout
public GridLayout()
From source file:edu.nps.moves.mmowgli.modules.userprofile.UserProfileMyIdeasPanel2.java
License:Open Source License
@SuppressWarnings("unchecked") private Component createProfileTL() { VerticalLayout lay = new VerticalLayout(); lay.setWidth("670px"); Label lab;/*w ww . j ava 2 s. c om*/ lay.addComponent(lab = new Label()); lab.setHeight("10px"); VerticalLayout innerVL = new VerticalLayout(); innerVL.setSpacing(true); innerVL.setMargin(true); innerVL.setWidth("100%"); //"90%"); innerVL.addStyleName("m-myideaprofile-table"); lay.addComponent(innerVL); GridLayout gridL = new GridLayout(); gridL.setColumns(2); gridL.addStyleName("m-userprofile-text"); gridL.setSpacing(true); CardType ct; int count = 0; int largest = -1; List<Card> lisPos = commonCriteria() .add(Restrictions.eq("cardType", ct = CardType .getCurrentPositiveIdeaCardTypeTL()/*CardTypeManager.getPositiveIdeaCardTypeTL()*/)) .list(); count += lisPos.size(); largest = Math.max(largest, lisPos.size()); List<Card> lisNeg = commonCriteria() .add(Restrictions.eq("cardType", ct = CardType.getCurrentNegativeIdeaCardTypeTL())).list(); //CardTypeManager.getNegativeIdeaCardTypeTL())).list(); count += lisNeg.size(); largest = Math.max(largest, lisNeg.size()); List<Card> lisExpand = commonCriteria().add(Restrictions.eq("cardType", ct = CardType.getExpandTypeTL())) .list();//CardTypeManager.getExpandTypeTL())).list(); count += lisExpand.size(); largest = Math.max(largest, lisExpand.size()); List<Card> lisAdapt = commonCriteria().add(Restrictions.eq("cardType", ct = CardType.getAdaptTypeTL())) .list();//CardTypeManager.getAdaptTypeTL())).list(); count += lisAdapt.size(); largest = Math.max(largest, lisAdapt.size()); List<Card> lisCounter = commonCriteria().add(Restrictions.eq("cardType", ct = CardType.getCounterTypeTL())) .list();//CardTypeManager.getCounterTypeTL())).list(); count += lisCounter.size(); largest = Math.max(largest, lisCounter.size()); List<Card> lisExplore = commonCriteria().add(Restrictions.eq("cardType", ct = CardType.getExploreTypeTL())) .list();//CardTypeManager.getExploreTypeTL())).list(); count += lisExplore.size(); largest = Math.max(largest, lisExplore.size()); ct = CardType.getCurrentPositiveIdeaCardTypeTL(); //CardTypeManager.getPositiveIdeaCardTypeTL(); row(ct.getSummaryHeader(), largest, lisPos.size(), ct, gridL); ct = CardType.getCurrentNegativeIdeaCardTypeTL(); //CardTypeManager.getNegativeIdeaCardTypeTL(); row(ct.getSummaryHeader(), largest, lisNeg.size(), ct, gridL); ct = CardType.getExpandTypeTL(); //CardTypeManager.getExpandTypeTL(); row(ct.getSummaryHeader(), largest, lisExpand.size(), ct, gridL); ct = CardType.getAdaptTypeTL(); //CardTypeManager.getAdaptTypeTL(); row(ct.getSummaryHeader(), largest, lisAdapt.size(), ct, gridL); ct = CardType.getCounterTypeTL(); //CardTypeManager.getCounterTypeTL(); row(ct.getSummaryHeader(), largest, lisCounter.size(), ct, gridL); ct = CardType.getExploreTypeTL(); //CardTypeManager.getExploreTypeTL(); row(ct.getSummaryHeader(), largest, lisExplore.size(), ct, gridL); gridL.addComponent(new Label("")); gridL.addComponent(new Label("")); gridL.addComponent(new Label("TOTAL")); gridL.addComponent(new Label("" + count)); innerVL.addComponent(gridL); lay.addComponent(lab = new Label()); lab.setHeight("1px"); lay.setExpandRatio(lab, 1.0f); return lay; }
From source file:edu.nps.moves.mmowgliMobile.ui.UserRenderer2.java
License:Open Source License
public void setMessage(FullEntryView2 mView, ListEntry message, ListView2 messageList, AbstractOrderedLayout layout) {// w w w . jav a 2s . c o m // messageList can be null if coming in from ActionPlan Object key = HSess.checkInit(); UserListEntry wu = (UserListEntry) message; User u = wu.getUser(); layout.removeAllComponents(); HorizontalLayout hlay = new HorizontalLayout(); layout.addComponent(hlay); hlay.addStyleName("m-userview-top"); hlay.setWidth("100%"); hlay.setMargin(true); hlay.setSpacing(true); Image img = new Image(); img.addStyleName("m-ridgeborder"); img.setSource(mediaLocator.locate(u.getAvatar().getMedia())); img.setWidth("90px"); img.setHeight("90px"); hlay.addComponent(img); hlay.setComponentAlignment(img, Alignment.MIDDLE_CENTER); Label lab; hlay.addComponent(lab = new Label()); lab.setWidth("5px"); VerticalLayout vlay = new VerticalLayout(); vlay.setSpacing(true); hlay.addComponent(vlay); hlay.setComponentAlignment(vlay, Alignment.MIDDLE_LEFT); vlay.setWidth("100%"); hlay.setExpandRatio(vlay, 1.0f); HorizontalLayout horl = new HorizontalLayout(); horl.setSpacing(false); vlay.addComponent(horl); vlay.setComponentAlignment(horl, Alignment.BOTTOM_LEFT); horl.addComponent(lab = new Label("name")); lab.addStyleName("m-user-top-label"); //light-text"); horl.addComponent(lab = new HtmlLabel(" " + u.getUserName())); lab.addStyleName("m-user-top-value"); horl = new HorizontalLayout(); horl.setSpacing(false); vlay.addComponent(horl); vlay.setComponentAlignment(horl, Alignment.TOP_LEFT); horl.addComponent(lab = new Label("level")); lab.addStyleName("m-user-top-label"); //light-text"); Level lev = u.getLevel(); if (u.isGameMaster()) { Level l = Level.getLevelByOrdinal(Level.GAME_MASTER_ORDINAL, HSess.get()); if (l != null) lev = l; } horl.addComponent(lab = new HtmlLabel(" " + lev.getDescription())); lab.addStyleName("m-user-top-value"); GridLayout gLay = new GridLayout(); // gLay.setHeight("155px"); // won't size properly gLay.setMargin(true); gLay.addStyleName("m-userview-mid"); gLay.setColumns(2); gLay.setRows(11); gLay.setSpacing(true); gLay.setWidth("100%"); gLay.setColumnExpandRatio(1, 1.0f); layout.addComponent(gLay); addRow(gLay, "user ID:", "" + getPojoId(message)); addRow(gLay, "location:", u.getLocation()); addRow(gLay, "expertise:", u.getExpertise()); addRow(gLay, "affiliation:", u.getAffiliation()); addRow(gLay, "date registered:", formatter.format(u.getRegisterDate())); gLay.addComponent(new Hr(), 0, 5, 1, 5); Container cntr = new CardsByUserContainer<Card>(u); // expects ThreadLocal session to be setup numCards = cntr.size(); addRow(gLay, "cards played:", "" + numCards); cntr = new ActionPlansByUserContainer<Card>(u); // expects ThreadLocal session to be setup numAps = cntr.size(); addRow(gLay, "action plans:", "" + numAps); gLay.addComponent(new Hr(), 0, 8, 1, 8); addRow(gLay, "exploration points:", "" + u.getBasicScore()); addRow(gLay, "innovation points:", "" + u.getInnovationScore()); cardListener = new CardLis(u, mView); apListener = new AppLis(u, mView); layout.addComponent(makeButtons()); HSess.checkClose(key); }
From source file:fr.univlorraine.mondossierweb.views.ListeInscritsView.java
License:Apache License
private void displayTrombinoscope() { List<Inscrit> linscrits = MainUI.getCurrent().getListeInscrits(); if (trombiLayout != null) { trombiLayout.removeAllComponents(); } else {//w w w.j a v a 2s . c om trombiLayout = new GridLayout(); trombiLayout.setColumns(5); trombiLayout.setWidth("100%"); trombiLayout.setHeight(null); trombiLayout.setSpacing(true); } for (Inscrit inscrit : linscrits) { if (listecodind.contains(inscrit.getCod_ind())) { VerticalLayout photoLayout = new VerticalLayout(); photoLayout.setId(inscrit.getCod_ind()); photoLayout.setHeight("100%"); if (inscrit.getUrlphoto() != null) { //Button fotoEtu=new Button(); Image fotoEtudiant = new Image(null, new ExternalResource(inscrit.getUrlphoto())); fotoEtudiant.setWidth("120px"); fotoEtudiant.setStyleName(ValoTheme.BUTTON_LINK); fotoEtudiant.addClickListener(e -> { rechercheController.accessToDetail(inscrit.getCod_etu().toString(), Utils.TYPE_ETU, null); }); photoLayout.addComponent(fotoEtudiant); //photoLayout.addComponent(fotoEtu); photoLayout.setComponentAlignment(fotoEtudiant, Alignment.MIDDLE_CENTER); photoLayout.setExpandRatio(fotoEtudiant, 1); } VerticalLayout nomCodeLayout = new VerticalLayout(); nomCodeLayout.setSizeFull(); nomCodeLayout.setSpacing(false); Button btnNomEtudiant = new Button(inscrit.getPrenom() + " " + inscrit.getNom()); btnNomEtudiant.setSizeFull(); btnNomEtudiant.setStyleName(ValoTheme.BUTTON_BORDERLESS); btnNomEtudiant.addStyleName("link"); btnNomEtudiant.addStyleName("v-link"); nomCodeLayout.addComponent(btnNomEtudiant); btnNomEtudiant.addClickListener(e -> { rechercheController.accessToDetail(inscrit.getCod_etu().toString(), Utils.TYPE_ETU, null); }); nomCodeLayout.setComponentAlignment(btnNomEtudiant, Alignment.MIDDLE_CENTER); //nomCodeLayout.setExpandRatio(btnNomEtudiant, 1); Label codetuLabel = new Label(inscrit.getCod_etu()); codetuLabel.setSizeFull(); codetuLabel.setStyleName(ValoTheme.LABEL_TINY); codetuLabel.addStyleName("label-centre"); nomCodeLayout.addComponent(codetuLabel); nomCodeLayout.setComponentAlignment(codetuLabel, Alignment.TOP_CENTER); photoLayout.addComponent(nomCodeLayout); trombiLayout.addComponent(photoLayout); trombiLayout.setComponentAlignment(photoLayout, Alignment.MIDDLE_CENTER); } } }
From source file:io.subutai.plugin.accumulo.ui.manager.Manager.java
public Manager(final ExecutorService executorService, final Accumulo accumulo, Hadoop hadoop, final Zookeeper zookeeper, Tracker tracker, EnvironmentManager environmentManager) throws NamingException { this.executorService = executorService; this.accumulo = accumulo; this.hadoop = hadoop; this.zookeeper = zookeeper; this.tracker = tracker; this.environmentManager = environmentManager; contentRoot = new GridLayout(); contentRoot.setSpacing(true);//from w ww.ja v a 2 s.c o m contentRoot.setMargin(true); contentRoot.setSizeFull(); contentRoot.setRows(10); contentRoot.setColumns(1); //tables go here mastersTable = createTableTemplate("Masters"); mastersTable.setId("MastersTable"); tracersTable = createTableTemplate("Tracers"); tracersTable.setId("TracersTable"); slavesTable = createTableTemplate("Tablet Servers"); slavesTable.setId("Slavestable"); HorizontalLayout controlsContent = new HorizontalLayout(); controlsContent.setSpacing(true); controlsContent.setHeight(100, Sizeable.Unit.PERCENTAGE); Label clusterNameLabel = new Label("Select the cluster"); controlsContent.addComponent(clusterNameLabel); controlsContent.setComponentAlignment(clusterNameLabel, Alignment.MIDDLE_CENTER); ComboBox clustersCombo = getClusterCombo(); controlsContent.addComponent(clustersCombo); controlsContent.setComponentAlignment(clustersCombo, Alignment.MIDDLE_CENTER); refreshClustersBtn = getRefreshClustersButton(); controlsContent.addComponent(refreshClustersBtn); controlsContent.setComponentAlignment(refreshClustersBtn, Alignment.MIDDLE_CENTER); checkAllBtn = getCheckAllButton(); controlsContent.addComponent(checkAllBtn); controlsContent.setComponentAlignment(checkAllBtn, Alignment.MIDDLE_CENTER); startClusterBtn = getStartAllButton(); controlsContent.addComponent(startClusterBtn); controlsContent.setComponentAlignment(startClusterBtn, Alignment.MIDDLE_CENTER); stopClusterBtn = getStopAllButton(); controlsContent.addComponent(stopClusterBtn); controlsContent.setComponentAlignment(stopClusterBtn, Alignment.MIDDLE_CENTER); destroyClusterBtn = getDestroyClusterButton(); controlsContent.addComponent(destroyClusterBtn); controlsContent.setComponentAlignment(destroyClusterBtn, Alignment.MIDDLE_CENTER); addTracerBtn = getAddTracerNodeButton(); controlsContent.addComponent(addTracerBtn); controlsContent.setComponentAlignment(addTracerBtn, Alignment.MIDDLE_CENTER); addTabletServerButton = getAddSlaveButton(); controlsContent.addComponent(addTabletServerButton); controlsContent.setComponentAlignment(addTabletServerButton, Alignment.MIDDLE_CENTER); //auto scale button autoScaleBtn = new CheckBox(AUTO_SCALE_BUTTON_CAPTION); autoScaleBtn.setValue(false); autoScaleBtn.addStyleName("default"); controlsContent.addComponent(autoScaleBtn); controlsContent.setComponentAlignment(autoScaleBtn, Alignment.MIDDLE_CENTER); autoScaleBtn.addValueChangeListener(new Property.ValueChangeListener() { @Override public void valueChange(final Property.ValueChangeEvent event) { if (accumuloClusterConfig == null) { show("Select cluster"); } else { boolean value = (Boolean) event.getProperty().getValue(); accumuloClusterConfig.setAutoScaling(value); try { accumulo.saveConfig(accumuloClusterConfig); } catch (ClusterException e) { show(e.getMessage()); } } } }); addStyleName(refreshClustersBtn, checkAllBtn, startClusterBtn, stopClusterBtn, destroyClusterBtn, addTracerBtn, addTabletServerButton); PROGRESS_ICON.setVisible(false); PROGRESS_ICON.setId("indicator"); controlsContent.addComponent(PROGRESS_ICON); controlsContent.setComponentAlignment(PROGRESS_ICON, Alignment.MIDDLE_CENTER); contentRoot.addComponent(controlsContent, 0, 0); contentRoot.addComponent(mastersTable, 0, 1, 0, 3); contentRoot.addComponent(tracersTable, 0, 4, 0, 6); contentRoot.addComponent(slavesTable, 0, 7, 0, 9); }
From source file:jcaster_vaadin.Gui2.java
License:Open Source License
@AutoGenerated private GridLayout buildGridLayout_3() { // common part: create layout gridLayout_3 = new GridLayout(); gridLayout_3.setWidth("100.0%"); gridLayout_3.setHeight("100.0%"); gridLayout_3.setImmediate(false);/*from w ww . ja v a 2s . c om*/ gridLayout_3.setMargin(false); gridLayout_3.setSpacing(true); gridLayout_3.setColumns(4); gridLayout_3.setRows(7); // flnmLbl flnmLbl = new Label(); flnmLbl.setWidth("-1px"); flnmLbl.setHeight("-1px"); flnmLbl.setValue("Filename"); flnmLbl.setImmediate(false); gridLayout_3.addComponent(flnmLbl, 0, 1); // txtFlnm txtFlnm = new TextField(); txtFlnm.setWidth("-1px"); txtFlnm.setHeight("-1px"); txtFlnm.setImmediate(false); txtFlnm.setValue("test"); //set default filename gridLayout_3.addComponent(txtFlnm, 1, 1); // svlcLbl svlcLbl = new Label(); svlcLbl.setWidth("-1px"); svlcLbl.setHeight("-1px"); svlcLbl.setValue("Save location"); svlcLbl.setImmediate(false); gridLayout_3.addComponent(svlcLbl, 0, 2); // txtSvLc txtSvLc = new TextField(); txtSvLc.setWidth("-1px"); txtSvLc.setHeight("-1px"); txtSvLc.setImmediate(false); txtSvLc.setValue(System.getProperty("user.home") + File.separator); gridLayout_3.addComponent(txtSvLc, 1, 2); // brwBtn brwBtn = new NativeButton(); brwBtn.setWidth("-1px"); brwBtn.setHeight("-1px"); brwBtn.setCaption("Browse..."); brwBtn.setImmediate(true); gridLayout_3.addComponent(brwBtn, 2, 2); brwBtn.addListener(new Button.ClickListener() { private static final long serialVersionUID = -8389582613309805795L; public void buttonClick(Button.ClickEvent event) { // browse(); } }); // rcrdLbl rcrdLbl = new Label(); rcrdLbl.setWidth("-1px"); rcrdLbl.setHeight("-1px"); rcrdLbl.setValue("Record type"); rcrdLbl.setImmediate(false); gridLayout_3.addComponent(rcrdLbl, 0, 3); // slctRrcdTp slctRrcdTp = new NativeSelect(); slctRrcdTp.setWidth("-1px"); slctRrcdTp.setHeight("-1px"); slctRrcdTp.setImmediate(false); slctRrcdTp.addItem("audio+video"); slctRrcdTp.addItem("video only"); slctRrcdTp.addItem("audio only"); slctRrcdTp.setValue("audio+video"); //set default record type gridLayout_3.addComponent(slctRrcdTp, 1, 3); // RcrdCtdLbl RcrdCtdLbl = new Label(); RcrdCtdLbl.setWidth("-1px"); RcrdCtdLbl.setHeight("-1px"); RcrdCtdLbl.setValue("Recording countdown"); RcrdCtdLbl.setImmediate(false); gridLayout_3.addComponent(RcrdCtdLbl, 0, 4); // txtRrcdCtd txtRrcdCtd = new TextField(); txtRrcdCtd.setWidth("-1px"); txtRrcdCtd.setHeight("-1px"); txtRrcdCtd.setValue(0); txtRrcdCtd.setImmediate(false); gridLayout_3.addComponent(txtRrcdCtd, 1, 4); // DrRcrdLbl DrRcrdLbl = new Label(); DrRcrdLbl.setWidth("-1px"); DrRcrdLbl.setHeight("-1px"); DrRcrdLbl.setValue("Duration of record"); DrRcrdLbl.setImmediate(false); gridLayout_3.addComponent(DrRcrdLbl, 0, 5); // txtDrRcrd txtDrRcrd = new TextField(); txtDrRcrd.setWidth("-1px"); txtDrRcrd.setHeight("-1px"); txtDrRcrd.setValue(0); txtDrRcrd.setImmediate(false); gridLayout_3.addComponent(txtDrRcrd, 1, 5); return gridLayout_3; }
From source file:jcaster_vaadin.Gui2.java
License:Open Source License
@AutoGenerated private GridLayout buildGridLayout_4() { // common part: create layout gridLayout_4 = new GridLayout(); gridLayout_4.setWidth("100.0%"); gridLayout_4.setHeight("100.0%"); gridLayout_4.setImmediate(false);// w w w . j a v a 2s . c o m gridLayout_4.setMargin(false); gridLayout_4.setSpacing(true); gridLayout_4.setColumns(5); gridLayout_4.setRows(7); // frmtLbl frmtLbl = new Label(); frmtLbl.setWidth("-1px"); frmtLbl.setHeight("-1px"); frmtLbl.setValue("Format"); frmtLbl.setImmediate(false); gridLayout_4.addComponent(frmtLbl, 0, 1); // slctFrmt slctFrmt = new NativeSelect(); slctFrmt.setWidth("-1px"); slctFrmt.setHeight("-1px"); slctFrmt.setImmediate(false); slctFrmt.addItem("mp4"); slctFrmt.addItem("avi"); slctFrmt.addItem("mov"); slctFrmt.addItem("flv"); slctFrmt.setValue("mp4"); //set default video format gridLayout_4.addComponent(slctFrmt, 1, 1); // cdcLbl cdcLbl = new Label(); cdcLbl.setWidth("-1px"); cdcLbl.setHeight("-1px"); cdcLbl.setValue("Codec"); cdcLbl.setImmediate(false); gridLayout_4.addComponent(cdcLbl, 0, 2); // slctCdc slctCdc = new NativeSelect(); slctCdc.setWidth("-1px"); slctCdc.setHeight("-1px"); slctCdc.setImmediate(false); gridLayout_4.addComponent(slctCdc, 1, 2); return gridLayout_4; }
From source file:jcaster_vaadin.Gui2.java
License:Open Source License
@AutoGenerated private GridLayout buildGridLayout_5() { // common part: create layout gridLayout_5 = new GridLayout(); gridLayout_5.setWidth("100.0%"); gridLayout_5.setHeight("100.0%"); gridLayout_5.setImmediate(false);//from w w w.j a v a 2 s.c om gridLayout_5.setMargin(false); gridLayout_5.setSpacing(true); gridLayout_5.setColumns(4); gridLayout_5.setRows(7); // chnlsLbl chnlsLbl = new Label(); chnlsLbl.setWidth("-1px"); chnlsLbl.setHeight("-1px"); chnlsLbl.setValue("Channels"); chnlsLbl.setImmediate(false); gridLayout_5.addComponent(chnlsLbl, 0, 1); // slctChnls slctChnls = new NativeSelect(); slctChnls.setWidth("-1px"); slctChnls.setHeight("-1px"); slctChnls.setImmediate(false); slctChnls.addItem(1); slctChnls.addItem(2); slctChnls.setValue(2); //set default number of channels gridLayout_5.addComponent(slctChnls, 1, 1); // smplSzLbl smplSzLbl = new Label(); smplSzLbl.setWidth("-1px"); smplSzLbl.setHeight("-1px"); smplSzLbl.setValue("Sample size"); smplSzLbl.setImmediate(false); gridLayout_5.addComponent(smplSzLbl, 0, 2); // slctSmplSz slctSmplSz = new NativeSelect(); slctSmplSz.setWidth("-1px"); slctSmplSz.setHeight("-1px"); slctSmplSz.setImmediate(false); slctSmplSz.addItem("8-bit"); slctSmplSz.addItem("16-bit"); slctSmplSz.setValue("16-bit"); //set default sample size gridLayout_5.addComponent(slctSmplSz, 1, 2); // splRtLbl splRtLbl = new Label(); splRtLbl.setWidth("-1px"); splRtLbl.setHeight("-1px"); splRtLbl.setValue("Sample rate"); splRtLbl.setImmediate(false); gridLayout_5.addComponent(splRtLbl, 0, 3); // slctSmplRt slctSmplRt = new NativeSelect(); slctSmplRt.setWidth("-1px"); slctSmplRt.setHeight("-1px"); slctSmplRt.setImmediate(false); slctSmplRt.addItem(8000); slctSmplRt.addItem(11025); slctSmplRt.addItem(16000); slctSmplRt.addItem(22050); slctSmplRt.addItem(44100); slctSmplRt.setValue(44100); //set default sample rate gridLayout_5.addComponent(slctSmplRt, 1, 3); return gridLayout_5; }
From source file:org.activiti.explorer.ui.management.identity.UserDetailPanel.java
License:Apache License
protected void loadUserDetails() { // Grid of details GridLayout detailGrid = new GridLayout(); detailGrid.setColumns(2);/* w w w . ja v a 2s .c o m*/ detailGrid.setSpacing(true); detailGrid.setMargin(true, true, false, true); userDetailsLayout.addComponent(detailGrid); // Details addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_ID), new Label(user.getId())); // details are non-editable if (!editingDetails) { addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_FIRSTNAME), new Label(user.getFirstName())); addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_LASTNAME), new Label(user.getLastName())); addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_EMAIL), new Label(user.getEmail())); } else { firstNameField = new TextField(null, user.getFirstName() != null ? user.getFirstName() : ""); addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_FIRSTNAME), firstNameField); firstNameField.focus(); lastNameField = new TextField(null, user.getLastName() != null ? user.getLastName() : ""); addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_LASTNAME), lastNameField); emailField = new TextField(null, user.getEmail() != null ? user.getEmail() : ""); addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_EMAIL), emailField); passwordField = new PasswordField(); Label cautionLabel = new Label(i18nManager.getMessage(Messages.USER_RESET_PASSWORD)); cautionLabel.addStyleName(Reindeer.LABEL_SMALL); HorizontalLayout passwordLayout = new HorizontalLayout(); passwordLayout.setSpacing(true); passwordLayout.addComponent(passwordField); passwordLayout.addComponent(cautionLabel); passwordLayout.setComponentAlignment(cautionLabel, Alignment.MIDDLE_LEFT); addUserDetail(detailGrid, i18nManager.getMessage(Messages.USER_PASSWORD), passwordLayout); } }
From source file:org.activiti.explorer.ui.task.HistoricTaskDetailPanel.java
License:Apache License
protected void initPeopleGrid() { peopleGrid = new GridLayout(); peopleGrid.setColumns(2);/*from w ww . j a va 2 s. com*/ peopleGrid.setSpacing(true); peopleGrid.setMargin(true, false, false, false); peopleGrid.setWidth(100, UNITS_PERCENTAGE); peopleLayout.addComponent(peopleGrid); }
From source file:org.activiti.explorer.ui.task.TaskEventsPanel.java
License:Apache License
protected void initEventGrid() { eventGrid = new GridLayout(); eventGrid.setColumns(2);//from www .j av a 2s . c o m eventGrid.setSpacing(true); eventGrid.setMargin(true, false, false, false); eventGrid.setWidth("100%"); eventGrid.setColumnExpandRatio(1, 1.0f); eventGrid.addStyleName(ExplorerLayout.STYLE_TASK_EVENT_GRID); addComponent(eventGrid); }