Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 272686

Summary: [Table] Javascript error during table disposal
Product: [RT] RAP Reporter: Ralf Sternberg <rsternberg>
Component: RWTAssignee: Project Inbox <rap-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: ivan
Version: 1.2   
Target Milestone: 1.2 M7   
Hardware: All   
OS: All   
Whiteboard:

Description Ralf Sternberg CLA 2009-04-17 09:00:45 EDT
Observed using FF 3.0.8 / Linux

Steps to reproduce:
* Open the controls demo
* Change to the table tab
* Check the NO_SCROLL checkbox
* Uncheck the NO_SCROLL check box again
* Reload

An error message occurs: "WARN: Could not dispose: [object qx.ui.layout.CanvasLayout]:  TypeError: columns[i] is null".

Might be a timing issue, so try several times.

Some quick analysis revealed that the error occurs in the method getColumnsWidth in Table.js.
Comment 1 Ivan Furnadjiev CLA 2009-04-21 05:18:26 EDT
When the table is disposed from within the RAP code, first the table is disposed and after that the table columns. This ensures that the Table.getDisposed() returns true in TableColumn.js and TableItem.js destruct method and the table is not re-rendered. When the browser refresh button is pressed, the TableColumn#destruct is called first, Table.getDisposed() returns false and table re-rendering is triggered. To prevent this the qx.core.Object.inGlobalDispose() is used in TableColumn and TableItem destruct method.