I am dynamically creating content in a qooxdoo desktop application based on ajax calls. Some of the content I am creating has a lot of widgets in it (on the order of 200+).
I did some profiling with google chrome and it looks like most of the processing time is taken up by the layout manager since I am calling add() on the container for every widget I create.
Is there a way to pause the layout manager while I add all the widgets and then have it run once at the very end?
Is there a better approach altogether for dynamically adding lots of widgets to containers?
Here is an example of what I am doing:
var container = new qx.ui.container.Composite(new qx.ui.layout.Flow());
var groupbox = new qx.ui.groupbox.GroupBox();
groupbox.setLayout(new qx.ui.layout.Grid(10, 10));
container.add(groupbox);
// loop through data received from AJAX call and add it to the group box
var row = 0;
data.each(function(pair) {
var label = new qx.ui.basic.Label(pair.key);
var field = new qx.ui.form.TextField(pair.value);
groupbox.add(label, {row: row, column: 0});
groupbox.add(field, {row: row, column: 1});
++row;
});