Java Code Examples for com.vaadin.ui.VerticalLayout#setWidth()
The following examples show how to use
com.vaadin.ui.VerticalLayout#setWidth() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: UserManagement.java From XACML with MIT License | 6 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("100%"); mainLayout.setHeight("-1px"); mainLayout.setMargin(false); // top-level component properties setWidth("100.0%"); setHeight("-1px"); // horizontalLayoutToolbar horizontalLayoutToolbar = buildHorizontalLayoutToolbar(); mainLayout.addComponent(horizontalLayoutToolbar); // tableUsers tableUsers = new Table(); tableUsers.setImmediate(false); tableUsers.setWidth("100.0%"); tableUsers.setHeight("-1px"); mainLayout.addComponent(tableUsers); return mainLayout; }
Example 2
Source File: PolicyWorkspace.java From XACML with MIT License | 6 votes |
@AutoGenerated private VerticalLayout buildVerticalLayoutRightPanel() { // common part: create layout verticalLayoutRightPanel = new VerticalLayout(); verticalLayoutRightPanel.setImmediate(false); verticalLayoutRightPanel.setWidth("100.0%"); verticalLayoutRightPanel.setHeight("-1px"); verticalLayoutRightPanel.setMargin(true); verticalLayoutRightPanel.setSpacing(true); // horizontalLayoutRightToolbar horizontalLayoutRightToolbar = buildHorizontalLayoutRightToolbar(); verticalLayoutRightPanel.addComponent(horizontalLayoutRightToolbar); // tabSheet tabSheet = new TabSheet(); tabSheet.setImmediate(true); tabSheet.setWidth("100.0%"); tabSheet.setHeight("-1px"); verticalLayoutRightPanel.addComponent(tabSheet); verticalLayoutRightPanel.setExpandRatio(tabSheet, 1.0f); return verticalLayoutRightPanel; }
Example 3
Source File: TargetBulkUpdateWindowLayout.java From hawkbit with Eclipse Public License 1.0 | 6 votes |
private void buildLayout() { mainLayout = new VerticalLayout(); mainLayout.setSpacing(Boolean.TRUE); mainLayout.setSizeUndefined(); mainLayout.setWidth("200px"); final HorizontalLayout captionLayout = new HorizontalLayout(); captionLayout.setSizeFull(); captionLayout.addComponents(windowCaption, minimizeButton, closeButton); captionLayout.setExpandRatio(windowCaption, 1.0F); captionLayout.addStyleName("v-window-header"); final HorizontalLayout uploaderLayout = new HorizontalLayout(); uploaderLayout.addComponent(bulkUploader); uploaderLayout.addComponent(linkToSystemConfigHelp); uploaderLayout.setComponentAlignment(linkToSystemConfigHelp, Alignment.BOTTOM_RIGHT); uploaderLayout.setExpandRatio(bulkUploader, 1.0F); uploaderLayout.setSizeFull(); mainLayout.addComponents(captionLayout, dsNamecomboBox, descTextArea, tokenVerticalLayout, descTextArea, progressBar, targetsCountLabel, uploaderLayout); }
Example 4
Source File: LoadBalancerDesc.java From primecloud-controller with GNU General Public License v2.0 | 5 votes |
@Override public void attach() { setWidth("100%"); setHeight("100%"); setCaption(ViewProperties.getCaption("panel.loadBalancerDesc")); addStyleName("loadbalancer-desc-panel"); addStyleName(Reindeer.PANEL_LIGHT); VerticalLayout layout = (VerticalLayout) getContent(); layout.setWidth("100%"); layout.setHeight("100%"); layout.setMargin(false); layout.setSpacing(false); layout.addStyleName("loadbalancer-desc-layout"); tab = new TabSheet(); tab.addStyleName(Reindeer.TABSHEET_BORDERLESS); tab.setWidth("100%"); tab.setHeight("100%"); addComponent(tab); // 基本情報 loadBalancerDescBasic = new LoadBalancerDescBasic(sender); tab.addTab(loadBalancerDescBasic, ViewProperties.getCaption("tab.loadBalancerDescBasic"), Icons.BASIC.resource()); // 詳細情報 loadBalancerDescServer = new LoadBalancerDescServer(sender); tab.addTab(loadBalancerDescServer, ViewProperties.getCaption("tab.loadBalancerDescServer"), Icons.DETAIL.resource()); tab.addListener(TabSheet.SelectedTabChangeEvent.class, this, "selectedTabChange"); }
Example 5
Source File: GitConflictResolver.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(false); // top-level component properties setWidth("-1px"); setHeight("-1px"); return mainLayout; }
Example 6
Source File: AttributeSelectionWindow.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // horizontalLayout_1 horizontalLayout_1 = buildHorizontalLayout_1(); mainLayout.addComponent(horizontalLayout_1); // horizontalLayoutAttribute horizontalLayoutAttribute = new HorizontalLayout(); horizontalLayoutAttribute.setImmediate(false); horizontalLayoutAttribute.setWidth("-1px"); horizontalLayoutAttribute.setHeight("-1px"); horizontalLayoutAttribute.setMargin(false); mainLayout.addComponent(horizontalLayoutAttribute); mainLayout.setExpandRatio(horizontalLayoutAttribute, 1.0f); // buttonSave buttonSave = new Button(); buttonSave.setCaption("Select"); buttonSave.setImmediate(true); buttonSave.setWidth("-1px"); buttonSave.setHeight("-1px"); mainLayout.addComponent(buttonSave); mainLayout.setComponentAlignment(buttonSave, new Alignment(48)); return mainLayout; }
Example 7
Source File: AttributeStandardSelectorComponent.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(false); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // comboBoxCategories comboBoxCategories = new ComboBox(); comboBoxCategories.setCaption("Select A Category"); comboBoxCategories.setImmediate(false); comboBoxCategories.setWidth("-1px"); comboBoxCategories.setHeight("-1px"); comboBoxCategories.setInvalidAllowed(false); comboBoxCategories.setRequired(true); mainLayout.addComponent(comboBoxCategories); mainLayout.setExpandRatio(comboBoxCategories, 1.0f); // horizontalLayout_2 horizontalLayout_2 = buildHorizontalLayout_2(); mainLayout.addComponent(horizontalLayout_2); mainLayout.setExpandRatio(horizontalLayout_2, 1.0f); return mainLayout; }
Example 8
Source File: SelectWorkspacePoliciesWindow.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // treeWorkspace treeWorkspace = new TreeTable(); treeWorkspace.setCaption("Select Policy(s) for PDP Group"); treeWorkspace.setImmediate(true); treeWorkspace.setWidth("100.0%"); treeWorkspace.setHeight("-1px"); mainLayout.addComponent(treeWorkspace); // buttonSave buttonSave = new Button(); buttonSave.setCaption("Save"); buttonSave.setImmediate(false); buttonSave.setWidth("-1px"); buttonSave.setHeight("-1px"); mainLayout.addComponent(buttonSave); mainLayout.setComponentAlignment(buttonSave, new Alignment(48)); return mainLayout; }
Example 9
Source File: SelectPDPGroupWindow.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // listSelectPDPGroup listSelectPDPGroup = new ListSelect(); listSelectPDPGroup.setImmediate(false); listSelectPDPGroup.setWidth("-1px"); listSelectPDPGroup.setHeight("-1px"); listSelectPDPGroup.setInvalidAllowed(false); listSelectPDPGroup.setRequired(true); mainLayout.addComponent(listSelectPDPGroup); mainLayout.setExpandRatio(listSelectPDPGroup, 1.0f); // buttonSave buttonSave = new Button(); buttonSave.setCaption("Save"); buttonSave.setImmediate(true); buttonSave.setWidth("-1px"); buttonSave.setHeight("-1px"); mainLayout.addComponent(buttonSave); mainLayout.setComponentAlignment(buttonSave, new Alignment(48)); return mainLayout; }
Example 10
Source File: GitSynchronizeWindow.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // textAreaResults textAreaResults = new TextArea(); textAreaResults.setCaption("Synch Results"); textAreaResults.setImmediate(false); textAreaResults.setWidth("462px"); textAreaResults.setHeight("222px"); mainLayout.addComponent(textAreaResults); // buttonSynchronize buttonSynchronize = new Button(); buttonSynchronize.setCaption("Synchronize"); buttonSynchronize.setImmediate(true); buttonSynchronize.setWidth("-1px"); buttonSynchronize.setHeight("-1px"); mainLayout.addComponent(buttonSynchronize); mainLayout.setComponentAlignment(buttonSynchronize, new Alignment(24)); return mainLayout; }
Example 11
Source File: PIPManagement.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("100%"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("100.0%"); setHeight("-1px"); // horizontalLayoutToolbar horizontalLayoutToolbar = buildHorizontalLayoutToolbar(); mainLayout.addComponent(horizontalLayoutToolbar); // tablePIP tablePIP = new Table(); tablePIP.setCaption("PIP Configurations"); tablePIP.setImmediate(false); tablePIP.setWidth("100.0%"); tablePIP.setHeight("-1px"); mainLayout.addComponent(tablePIP); return mainLayout; }
Example 12
Source File: ObligationAdviceEditorWindow.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("100%"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // horizontalLayout_1 horizontalLayout_1 = buildHorizontalLayout_1(); mainLayout.addComponent(horizontalLayout_1); // tableExpressions tableExpressions = new TreeTable(); tableExpressions.setCaption("Expressions"); tableExpressions.setImmediate(false); tableExpressions.setWidth("100%"); tableExpressions.setHeight("-1px"); mainLayout.addComponent(tableExpressions); mainLayout.setExpandRatio(tableExpressions, 1.0f); // buttonSave buttonSave = new Button(); buttonSave.setCaption("Save"); buttonSave.setImmediate(false); buttonSave.setWidth("-1px"); buttonSave.setHeight("-1px"); mainLayout.addComponent(buttonSave); mainLayout.setComponentAlignment(buttonSave, new Alignment(48)); return mainLayout; }
Example 13
Source File: OaExpressionsEditorComponent.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(false); // top-level component properties setWidth("-1px"); setHeight("-1px"); // tableExpressions tableExpressions = new Table(); tableExpressions.setCaption("Expressions"); tableExpressions.setImmediate(false); tableExpressions .setDescription("The list of expressions for the obligation/advice object."); tableExpressions.setWidth("-1px"); tableExpressions.setHeight("-1px"); mainLayout.addComponent(tableExpressions); // horizontalLayout_1 horizontalLayout_1 = buildHorizontalLayout_1(); mainLayout.addComponent(horizontalLayout_1); return mainLayout; }
Example 14
Source File: AttributeDictionary.java From XACML with MIT License | 5 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // horizontalLayoutToolbar horizontalLayoutToolbar = buildHorizontalLayoutToolbar(); mainLayout.addComponent(horizontalLayoutToolbar); // table table = new Table(); table.setImmediate(false); table.setWidth("100.0%"); table.setHeight("-1px"); mainLayout.addComponent(table); return mainLayout; }
Example 15
Source File: LDAPPIPConfigurationComponent.java From XACML with MIT License | 4 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // textFieldFactory textFieldFactory = new TextField(); textFieldFactory.setCaption("Initial Context Factory"); textFieldFactory.setImmediate(false); textFieldFactory.setWidth("-1px"); textFieldFactory.setHeight("-1px"); textFieldFactory.setInvalidAllowed(false); textFieldFactory.setRequired(true); textFieldFactory.setInputPrompt("com.sun.jndi.ldap.LdapCtxFactory"); mainLayout.addComponent(textFieldFactory); mainLayout.setExpandRatio(textFieldFactory, 1.0f); // textFieldProviderURL textFieldProviderURL = new TextField(); textFieldProviderURL.setCaption("Provider URL"); textFieldProviderURL.setImmediate(false); textFieldProviderURL.setWidth("-1px"); textFieldProviderURL.setHeight("-1px"); textFieldProviderURL.setInvalidAllowed(false); textFieldProviderURL.setRequired(true); textFieldProviderURL .setInputPrompt("Eg. ldap://localhost:389/o=JNDITutorial"); mainLayout.addComponent(textFieldProviderURL); mainLayout.setExpandRatio(textFieldProviderURL, 1.0f); // comboBoxAuthentication comboBoxAuthentication = new ComboBox(); comboBoxAuthentication.setCaption("Authentication"); comboBoxAuthentication.setImmediate(false); comboBoxAuthentication.setWidth("-1px"); comboBoxAuthentication.setHeight("-1px"); comboBoxAuthentication.setRequired(true); mainLayout.addComponent(comboBoxAuthentication); mainLayout.setExpandRatio(comboBoxAuthentication, 1.0f); // textFieldPrincipal textFieldPrincipal = new TextField(); textFieldPrincipal.setCaption("Principal"); textFieldPrincipal.setImmediate(false); textFieldPrincipal.setWidth("-1px"); textFieldPrincipal.setHeight("-1px"); textFieldPrincipal.setNullSettingAllowed(true); mainLayout.addComponent(textFieldPrincipal); mainLayout.setExpandRatio(textFieldPrincipal, 1.0f); // textFieldCredentials textFieldCredentials = new TextField(); textFieldCredentials.setCaption("Credentials"); textFieldCredentials.setImmediate(false); textFieldCredentials.setWidth("-1px"); textFieldCredentials.setHeight("-1px"); textFieldCredentials.setNullSettingAllowed(true); mainLayout.addComponent(textFieldCredentials); mainLayout.setExpandRatio(textFieldCredentials, 1.0f); // textFieldScope textFieldScope = new TextField(); textFieldScope.setCaption("Scope"); textFieldScope.setImmediate(false); textFieldScope.setWidth("-1px"); textFieldScope.setHeight("-1px"); textFieldScope.setInvalidAllowed(false); textFieldScope.setRequired(true); textFieldScope.setInputPrompt("Eg. subtree"); mainLayout.addComponent(textFieldScope); // buttonTest buttonTest = new Button(); buttonTest.setCaption("Test Connection"); buttonTest.setImmediate(true); buttonTest.setWidth("-1px"); buttonTest.setHeight("-1px"); mainLayout.addComponent(buttonTest); mainLayout.setComponentAlignment(buttonTest, new Alignment(48)); return mainLayout; }
Example 16
Source File: LoadBalancerDescBasic.java From primecloud-controller with GNU General Public License v2.0 | 4 votes |
@Override public void attach() { addStyleName(Reindeer.PANEL_LIGHT); setHeight("100%"); HorizontalLayout layout = new HorizontalLayout(); layout.setWidth("100%"); layout.setHeight("100%"); layout.setMargin(true); layout.setSpacing(true); layout.addStyleName("loadbalancer-desc-basic"); setContent(layout); // ロードバランサ基本情報 basicInfo = new BasicInfo(); basicInfo.setWidth("100%"); layout.addComponent(basicInfo); // 表同士の間隔をあける Label padding = new Label(" "); padding.setWidth("7px"); padding.setHeight("99%"); padding.addStyleName("desc-padding"); layout.addComponent(padding); Label padding2 = new Label(""); padding2.setWidth("1px"); layout.addComponent(padding2); // ロードバランサリスナ一覧 VerticalLayout rightLayout = new VerticalLayout(); rightLayout.setWidth("100%"); rightLayout.setHeight("100%"); rightLayout.setMargin(false); rightLayout.setSpacing(false); attachServiceTable = new AttachServiceTable(); attachServiceTable.setWidth("100%"); rightLayout.addComponent(attachServiceTable); loadBalancerOpe = new LoadbalancerServiceOperation(); rightLayout.addComponent(loadBalancerOpe); rightLayout.setExpandRatio(attachServiceTable, 100); layout.addComponent(rightLayout); layout.setExpandRatio(basicInfo, 43); layout.setExpandRatio(rightLayout, 57); }
Example 17
Source File: CSVPIPConfigurationComponent.java From XACML with MIT License | 4 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // textFieldFile textFieldFile = new TextField(); textFieldFile.setCaption("Path to CSV File"); textFieldFile.setImmediate(false); textFieldFile .setDescription("This is the path to CSV file on the PDP node."); textFieldFile.setWidth("-1px"); textFieldFile.setHeight("-1px"); textFieldFile.setInvalidAllowed(false); textFieldFile.setRequired(true); textFieldFile .setInputPrompt("Eg. \"c:\\data.csv\" \"http://foo.com/data.csv\""); mainLayout.addComponent(textFieldFile); mainLayout.setExpandRatio(textFieldFile, 1.0f); // textFieldDelimiter textFieldDelimiter = new TextField(); textFieldDelimiter.setCaption("Delimiter"); textFieldDelimiter.setImmediate(false); textFieldDelimiter .setDescription("Enter a separator character or string that delineates columns in each row."); textFieldDelimiter.setWidth("-1px"); textFieldDelimiter.setHeight("-1px"); textFieldDelimiter.setInputPrompt("Eg. \",\" or \"|\""); textFieldDelimiter.setNullSettingAllowed(true); mainLayout.addComponent(textFieldDelimiter); mainLayout.setExpandRatio(textFieldDelimiter, 1.0f); // textFieldQuote textFieldQuote = new TextField(); textFieldQuote.setCaption("Quote"); textFieldQuote.setImmediate(false); textFieldQuote .setDescription("Enter character used for quoted elements."); textFieldQuote.setWidth("-1px"); textFieldQuote.setHeight("-1px"); textFieldQuote.setInputPrompt("Eg. \" or '"); textFieldQuote.setNullSettingAllowed(true); mainLayout.addComponent(textFieldQuote); // textFieldSkip textFieldSkip = new TextField(); textFieldSkip.setCaption("Skip Lines"); textFieldSkip.setImmediate(false); textFieldSkip .setDescription("Skips the number of lines at the beginning of the file."); textFieldSkip.setWidth("-1px"); textFieldSkip.setHeight("-1px"); textFieldSkip.setInputPrompt("Eg. 1 or 2"); mainLayout.addComponent(textFieldSkip); return mainLayout; }
Example 18
Source File: EditPDPWindow.java From XACML with MIT License | 4 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // textId textId = new TextField(); textId.setCaption("PDP URL"); textId.setImmediate(false); textId.setDescription("The URL is the ID of the PDP"); textId.setWidth("-1px"); textId.setHeight("-1px"); textId.setRequired(true); textId.setInputPrompt("Eg. http://localhost:8080/pdp"); mainLayout.addComponent(textId); // textName textName = new TextField(); textName.setCaption("PDP Name"); textName.setImmediate(false); textName.setWidth("-1px"); textName.setHeight("-1px"); mainLayout.addComponent(textName); // textDescription textDescription = new TextArea(); textDescription.setCaption("PDP Description"); textDescription.setImmediate(false); textDescription.setWidth("100.0%"); textDescription.setHeight("-1px"); textDescription.setNullSettingAllowed(true); mainLayout.addComponent(textDescription); mainLayout.setExpandRatio(textDescription, 1.0f); // buttonSave buttonSave = new Button(); buttonSave.setCaption("Save"); buttonSave.setImmediate(true); buttonSave.setWidth("-1px"); buttonSave.setHeight("-1px"); mainLayout.addComponent(buttonSave); mainLayout.setComponentAlignment(buttonSave, new Alignment(48)); return mainLayout; }
Example 19
Source File: SQLPIPConfigurationComponent.java From XACML with MIT License | 4 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(false); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // comboBoxConnectionType comboBoxConnectionType = new ComboBox(); comboBoxConnectionType.setCaption("Type of SQL Connection"); comboBoxConnectionType.setImmediate(false); comboBoxConnectionType.setWidth("-1px"); comboBoxConnectionType.setHeight("-1px"); mainLayout.addComponent(comboBoxConnectionType); // textFieldDataSource textFieldDataSource = new TextField(); textFieldDataSource.setCaption("Data Source"); textFieldDataSource.setImmediate(false); textFieldDataSource.setWidth("-1px"); textFieldDataSource.setHeight("-1px"); mainLayout.addComponent(textFieldDataSource); mainLayout.setExpandRatio(textFieldDataSource, 1.0f); // comboBoxSQLDriver comboBoxSQLDriver = new ComboBox(); comboBoxSQLDriver.setCaption("JDBC Driver"); comboBoxSQLDriver.setImmediate(false); comboBoxSQLDriver.setWidth("-1px"); comboBoxSQLDriver.setHeight("-1px"); mainLayout.addComponent(comboBoxSQLDriver); mainLayout.setExpandRatio(comboBoxSQLDriver, 1.0f); // textFieldConnectionURL textFieldConnectionURL = new TextField(); textFieldConnectionURL.setCaption("Connection URL"); textFieldConnectionURL.setImmediate(false); textFieldConnectionURL.setWidth("-1px"); textFieldConnectionURL.setHeight("-1px"); mainLayout.addComponent(textFieldConnectionURL); mainLayout.setExpandRatio(textFieldConnectionURL, 1.0f); // textFieldUser textFieldUser = new TextField(); textFieldUser.setCaption("User"); textFieldUser.setImmediate(false); textFieldUser.setWidth("-1px"); textFieldUser.setHeight("-1px"); mainLayout.addComponent(textFieldUser); mainLayout.setExpandRatio(textFieldUser, 1.0f); // textFieldPassword textFieldPassword = new PasswordField(); textFieldPassword.setCaption("Password"); textFieldPassword.setImmediate(false); textFieldPassword.setWidth("-1px"); textFieldPassword.setHeight("-1px"); mainLayout.addComponent(textFieldPassword); mainLayout.setExpandRatio(textFieldPassword, 1.0f); // buttonTest buttonTest = new Button(); buttonTest.setCaption("Test Connection"); buttonTest.setImmediate(true); buttonTest.setWidth("-1px"); buttonTest.setHeight("-1px"); mainLayout.addComponent(buttonTest); mainLayout.setComponentAlignment(buttonTest, new Alignment(48)); return mainLayout; }
Example 20
Source File: GitPushWindow.java From XACML with MIT License | 4 votes |
@AutoGenerated private VerticalLayout buildMainLayout() { // common part: create layout mainLayout = new VerticalLayout(); mainLayout.setImmediate(false); mainLayout.setWidth("-1px"); mainLayout.setHeight("-1px"); mainLayout.setMargin(true); mainLayout.setSpacing(true); // top-level component properties setWidth("-1px"); setHeight("-1px"); // textAreaComments textAreaComments = new TextArea(); textAreaComments.setCaption("Add Comments"); textAreaComments.setImmediate(false); textAreaComments .setDescription("Enter comments that reflect the changes you have made to the repository domains and/or policy files."); textAreaComments.setWidth("400px"); textAreaComments.setHeight("-1px"); textAreaComments.setInvalidAllowed(false); textAreaComments.setRequired(true); textAreaComments .setInputPrompt("Eg. Add new rule for employees in marketing department."); mainLayout.addComponent(textAreaComments); // tableChanges tableChanges = new Table(); tableChanges.setCaption("Changes To Be Pushed"); tableChanges.setImmediate(false); tableChanges.setWidth("100.0%"); tableChanges.setHeight("-1px"); mainLayout.addComponent(tableChanges); mainLayout.setExpandRatio(tableChanges, 1.0f); // buttonPush buttonPush = new Button(); buttonPush.setCaption("Push Changes"); buttonPush.setImmediate(true); buttonPush.setWidth("-1px"); buttonPush.setHeight("-1px"); mainLayout.addComponent(buttonPush); mainLayout.setComponentAlignment(buttonPush, new Alignment(48)); return mainLayout; }