Vaadin 6 to Vaadin 7

Hello,

Someone please help me to use the Vaadin 6 méthods in Vaadin 7?

[b]

setMainWindow
(new
Window
(“Sender”, new VeveVue()));

button_1.
addListener
(new
Button.ClickListener()

mainLayout.[u]
addComponent
/u;


getWindow().showNotification

[/b]

Thank you,

  • There’s no main window in Vaadin 7. But you have to set a (usually layout) component as the UI content with setContent()
  • addListener(ClickListener) → addClickListener
  • Your mainLayout is apparently an AbsoluteLayout. It still works like that.
  • Easiest: Notification.show() or new Notification(…).show(), etc.

You might also be interested in getPage().setTitle(String) for setting title in the browser.