Advertisement
Guest User

Untitled

a guest
Nov 21st, 2019
123
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.76 KB | None | 0 0
  1. package it.zero11.vaadin.course.view;
  2.  
  3. import javax.swing.plaf.basic.BasicSliderUI.ScrollListener;
  4.  
  5. import com.vaadin.flow.component.html.Footer;
  6. import com.vaadin.flow.component.html.H1;
  7. import com.vaadin.flow.component.html.Paragraph;
  8. import com.vaadin.flow.component.orderedlayout.VerticalLayout;
  9. import com.vaadin.flow.router.Route;
  10.  
  11. @Route("example")
  12. public class ExampleView extends VerticalLayout {
  13. public ExampleView() {
  14. // TODO Auto-generated constructor stub
  15. setSizeFull();
  16. add(new H1("Title"));
  17. VerticalLayout scrollLayout = new VerticalLayout();
  18. scrollLayout.getStyle().set("overflow-y", "auto");
  19. for(int i =1; i <=100; i++) {
  20. scrollLayout.add(new Paragraph("prova" + i));
  21. }
  22. add(scrollLayout);
  23. add(new H1("Footer"));
  24. }
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement