VLayout problem

Hello,

I just have a problem with a vlayout. I would like to have two windows on top of each other. They should fill up the whole browser. If I resize the browser (smaller) the minimum height of each window should be 300px. Without the minimum height it is possible that the below window is too small and you are not able to use the scrollbar. If the size of a windows is to small, a scrollbar on the right side should be shown.

I try to use the following code:

VLayout layout = new VLayout();
layout.setOverflow(Overflow.HIDDEN);
layout.setWidth100();
layout.setHeight100();
layout.setMinHeight(500);
layout.addMember(createWin());  
layout.addMember(createWin());  
layout.draw();

private Window createWin() {  
	         Label label = new Label(  
	                 "<b>Severity 1</b> - Critical problem<br/>System is unavailable in production or is corrupting data, and the error severely impacts the user's operations.<br/><br/>"  
	                         + "<b>Severity 2</b> - Major problem<br/>An important function of the system is not available in production, and the user's operations are restricted.<br/><br/>"  
	                         + "<b>Severity 3</b> - Minor problem<br/>Inability to use a function of the system occurs, but it does not seriously affect the user's operations.");  
	         label.setPadding(5);  
	         Window window = new Window();  
	         window.setTitle("Titel");  
	         window.addItem(label);  
	         window.setMinHeight(300);
	         return window;  
	     }

Does anyone have a good idea?
Thanks in advance

I found the solution.
With addResizedHandler it was possible to create such a layout.