Core TreeTable Remove Items bug

Perhaps this is similar to ticket

treeTable.removeAllItems(); seems not to reflect on the client/ui side immediately until ?debug is added to the url.

The code below is slightly modified version of the code for the ticket 7780, which demonstrates this problem .
Hope there is a fix for this.

public class Test extends VerticalLayout implements Button.ClickListener {

	private static final long serialVersionUID = 5970642438709317165L;
	protected static final String NAME_PROPERTY = "Name";
	protected static final String HOURS_PROPERTY = "Hours done";
	protected static final String MODIFIED_PROPERTY = "Last Modified";

	protected final TreeTable treetable;

	public Test() {

		// Calendar
		Calendar cal = Calendar.getInstance();
		cal.set(2011, 10, 30, 14, 40, 26);

		// Create the treetable
		treetable = new TreeTable();

		Button rmvBtn = new Button("Remove All");


		// Add Table columns
		treetable.addContainerProperty(NAME_PROPERTY, String.class, "");
		treetable.addContainerProperty(HOURS_PROPERTY, Integer.class, 0);
		treetable.addContainerProperty(MODIFIED_PROPERTY, Date.class, cal.getTime());

		// Populate table
		Object allProjects = treetable.addItem(new Object[] { "All Projects", 18, cal.getTime() }, null);
		Object year2010 = treetable.addItem(new Object[] { "Year 2010", 18, cal.getTime() }, null);
		Object customerProject1 = treetable.addItem(new Object[] { "Customer Project 1", 13, cal.getTime() }, null);
		Object customerProject1Implementation = treetable.addItem(new Object[] { "Implementation", 5, cal.getTime() }, null);
		Object customerProject1Planning = treetable.addItem(new Object[] { "Planning", 2, cal.getTime() }, null);
		Object customerProject1Prototype = treetable.addItem(new Object[] { "Prototype", 5, cal.getTime() }, null);
		Object customerProject2 = treetable.addItem(new Object[] { "Customer Project 2", 5, cal.getTime() }, null);
		Object customerProject2Planning = treetable.addItem(new Object[] { "Planning", 5, cal.getTime() }, null);

		// Set hierarchy
		treetable.setParent(year2010, allProjects);
		treetable.setParent(customerProject1, year2010);
		treetable.setParent(customerProject1Implementation, customerProject1);
		treetable.setParent(customerProject1Planning, customerProject1);
		treetable.setParent(customerProject1Prototype, customerProject1);
		treetable.setParent(customerProject2, year2010);
		treetable.setParent(customerProject2Planning, customerProject2);

		// Disallow children from leaves
		treetable.setChildrenAllowed(customerProject1Implementation, false);
		treetable.setChildrenAllowed(customerProject1Planning, false);
		treetable.setChildrenAllowed(customerProject1Prototype, false);
		treetable.setChildrenAllowed(customerProject2Planning, false);

		// Expand all
		treetable.setCollapsed(allProjects, false);
		treetable.setCollapsed(year2010, false);
		treetable.setCollapsed(customerProject1, false);
		treetable.setCollapsed(customerProject2, false);


	public void buttonClick(ClickEvent event) {
		System.out.println("Test.buttonClick()" );


This seems to be the same issue as
. This ticket has recently been fixed and the fix is available in recent nightly builds and will also be in Vaadin 6.7.1 once it is released.

Thanks, I must have filtered out the closed tickets in the trac.

I tested your code out with a nightly and it works with that one.

(I have another TreeTable + removeAllItems() -issue that was quite close to that one which has not been fixed yet, and I just wanted to make sure)