-
Notifications
You must be signed in to change notification settings - Fork 24
Open
Labels
Description
Originally by draken
Using the code below, I've created a simple navigation view to be displayed inside a NavigationManager. It displays OK if the user keeps their device's orientation the same. However if the user changes the device orientation, the display is not updated, causing buttons and fields to sometimes disappear off the device. This seems odd as it doesn't happen on other screens, their layout updates to the screen orientation. This is using Vaadin 7.3.1 and Touchkit 4.0.0. I've attached screenshots of the issue
public class TestView extends NavigationView {
public TestView(){
Button leftButton = new Button();
leftButton.setIcon(FontAwesome.CHEVRON_LEFT);
leftButton.setWidth("45%");
Button rightButton = new Button();
rightButton.setIcon(FontAwesome.CHEVRON_RIGHT);
rightButton.setWidth("45%");
Label label = new Label("Test");
label.setWidth("100%");
GridLayout gridLayout = new GridLayout(2, 2);
gridLayout.addComponent(label, 0,0,1,0);
gridLayout.addComponent(leftButton, 0,1);
gridLayout.addComponent(rightButton, 1,1);
gridLayout.setComponentAlignment(rightButton, Alignment.TOP_RIGHT);
gridLayout.setSizeFull();
this.setContent(gridLayout);
}
}
Imported from https://dev.vaadin.com/ issue #19708