Hi,
I've just started to work with qooxdoo and spent two days
experimenting with it, reading source code and API reference, but I'm
still experiencing a lot of rather basic problems. If somebody can
point to a tutorial where all of this is explained, please let me know.
I'm trying to set up a remote table getting its data from a PHP script
using JSON, all based on the remote table tutorial in the qooxdoo
reference manual. However, I'm still struggling with the GUI.
1) The table appears but there is no data in it. The data get's loaded
correctly if I click somewhere in the grey area around it or if I
click on a "Get Data" button which sets the focus on the table or if I
click on the table header. Trying to set the focus by calling
"table.focus()" after the table gets added to the container has no effect.
2) I cannot select any rows. Though I can call the sort method in the
table header which reloads the data (as it should, according to the
tutorial). Changing the selection model does not solve the problem.
Something more seems to be needed - I cannot figure out what. (Nor can
I edit cells if I try to set the columns editable.)
3) There is no vertical scrollbar. Data which doesn't fit in the table
gets cut off. However, I suppose there should be one by default,
shouldn't it?
These problems make me think that I lack a fundamental understanding
of how to work with qooxdoo. Maybe someone can give me a hint. Thanks
in advance!
Michael
/**************** CODE **************************/
var tableModel = new firstap.mytable();
tableModel.setColumns( [ "ID", "Produkt", "checkbox" ],
[ "id", "title", "" ]);
var table = new qx.ui.table.Table(tableModel);
table.set( {width : 800});
table.getSelectionModel().setSelectionMode(1); //I supposed this would
make rows selectable - what else is needed?
table.setColumnWidth(0, 200);
table.getTableModel().setColumnEditable(1, true); // NO EFFECT
table.highlightFocusedRow(true);
var c = new qx.ui.container.Composite(new qx.ui.layout.Canvas);
c.set( {
width : 1000 });
c.add(table, {left : 20});
table.focus(); //NO EFFECT
var GetDataButton = new qx.ui.form.Button("Get Data", "");
c.add(GetDataButton, {left : 900});
GetDataButton.addListener("execute", function() {
table.focus();
}, this);
/* DISPLAY */
var doc = this.getRoot();
doc.add(c);
/*************** END ***************/
------------------------------------------------------------------------------
Register Now & Save for Velocity, the Web Performance & Operations
Conference from O'Reilly Media. Velocity features a full day of
expert-led, hands-on workshops and two days of sessions from industry
leaders in dedicated Performance & Operations tracks. Use code vel09scf
and Save an extra 15% before 5/3. http://p.sf.net/sfu/velocityconf
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel