You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

RefreshStatePreserveTitle.java 833B

123456789101112131415161718192021222324252627282930
  1. package com.vaadin.tests.application;
  2. import com.vaadin.annotations.PreserveOnRefresh;
  3. import com.vaadin.server.VaadinRequest;
  4. import com.vaadin.tests.components.AbstractTestUI;
  5. import com.vaadin.tests.util.Log;
  6. import com.vaadin.ui.Label;
  7. @PreserveOnRefresh
  8. public class RefreshStatePreserveTitle extends AbstractTestUI {
  9. private Log log = new Log(5);
  10. @Override
  11. protected void setup(VaadinRequest request) {
  12. getPage().setTitle("TEST");
  13. addComponent(new Label(
  14. "Refresh the page and observe that window title 'TEST' is lost."));
  15. }
  16. @Override
  17. protected String getTestDescription() {
  18. return "Refreshing the browser window should preserve the window title";
  19. }
  20. @Override
  21. protected Integer getTicketNumber() {
  22. return Integer.valueOf(11054);
  23. }
  24. }