diff options
author | Artur Signell <artur@vaadin.com> | 2014-12-04 09:13:15 +0200 |
---|---|---|
committer | Vaadin Code Review <review@vaadin.com> | 2014-12-11 11:07:44 +0000 |
commit | c0f689891ca05e9e74d184ee7528e1aadde84023 (patch) | |
tree | 50284ac8833f959bbb1d8e100a75ae295d23c383 | |
parent | 862a2f74d9f137560fe62a33a5b23e4dd31aeeae (diff) | |
download | vaadin-framework-c0f689891ca05e9e74d184ee7528e1aadde84023.tar.gz vaadin-framework-c0f689891ca05e9e74d184ee7528e1aadde84023.zip |
Test UI for #15321
Change-Id: I108f8ad473e6637bff9619f110f9194a56482c3e
-rw-r--r-- | uitest/src/com/vaadin/tests/layouts/HorizontalLayoutWithLabelAndButton.java | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/uitest/src/com/vaadin/tests/layouts/HorizontalLayoutWithLabelAndButton.java b/uitest/src/com/vaadin/tests/layouts/HorizontalLayoutWithLabelAndButton.java new file mode 100644 index 0000000000..9381f2caeb --- /dev/null +++ b/uitest/src/com/vaadin/tests/layouts/HorizontalLayoutWithLabelAndButton.java @@ -0,0 +1,43 @@ +/* + * Copyright 2000-2014 Vaadin Ltd. + * + * Licensed under the Apache License, Version 2.0 (the "License"); you may not + * use this file except in compliance with the License. You may obtain a copy of + * the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT + * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the + * License for the specific language governing permissions and limitations under + * the License. + */ +package com.vaadin.tests.layouts; + +import com.vaadin.server.VaadinRequest; +import com.vaadin.tests.components.AbstractTestUIWithLog; +import com.vaadin.ui.Button; +import com.vaadin.ui.HorizontalLayout; +import com.vaadin.ui.Label; + +public class HorizontalLayoutWithLabelAndButton extends AbstractTestUIWithLog { + + @Override + protected void setup(VaadinRequest request) { + HorizontalLayout hl = new HorizontalLayout(); + hl.setSpacing(true); + hl.setWidth("100%"); + Label l = new Label(); + l.setCaption("POTUS Database"); + l.setSizeUndefined(); + + Button b = new Button("Add new"); + hl.addComponents(l, b); + b.setStyleName("primary"); + hl.setExpandRatio(b, 1); + + addComponent(hl); + } + +} |