Hi Derrel,
I think you've been misled by my example, that was just the shortest way I
could think to demonstrate the issue.
I've subclassed the abstract table model, and the subclass holds an array
of items that are represented by rows in the table.
When that array gets updated, or when one of the items in the array
changes, I fire a "dataChanged" event which prompts the table to re-render
the area of the table that has changed.
I believe this is how it's intended to be used? it certainly works.
Nick Tindall
Derrell Lipman
<derrell.lipman@u
nwireduniverse.co To
m> qooxdoo Development
<[email protected]
26/05/11 12:48 PM t>
cc
Please respond to Subject
qooxdoo Re: [qooxdoo-devel]
Development qx.ui.table.model.Abstract: Null
<qooxdoo-devel@li data value on dataChanged event?
sts.sourceforge.n
et>
On Wed, May 25, 2011 at 22:13, <[email protected]>
wrote:
I've been working with the Abstract table model recently and in the
documentation for the dataChanged event it says
"Fired when the table data changed (the stuff shown in the table body).
The
data property of the event may be null or a map having the following
attributes: ....."
Given that description I assumed that firing the event with null as the
data parameter would signify the whole table needs updating, but when I
attempted it the qx.ui.table.Table throws an error:
"TypeError: Cannot read property 'firstRow' of null"
I attemped it just omitting the data parameter from fireDataEvent with a
similar result ("undefined" instead of "null")
Is the documentation or the behaviour of the table/tableModel wrong in
this
instance?
An example using Simple table model can be found here:
http://goo.gl/JmDHG
Hi Nick,
I think you've misunderstood events in qooxdoo. In general, _you_ don't
fire events to the widgets; rather, you listen for events that are fired
_by_ the widgets. That is true of the "dataChanged" event in the table
model. When the data model gets changed, e.g. by the user editing a cell in
the table, the "dataChanged" event is fired so that your program can
determine that the data changed, and possibly act on that change (maybe by
sending the altered data to a server someplace).
I'm not quite sure what it is you're actually trying to accomplish, though.
You haven't provided nay data to be displayed in the table. What do you
expect to be happening?
You should probably have a look at some table demos, such as:
http://demo.qooxdoo.org/1.4.x/playground/#Table
Cheers,
Derrell
_____________________________________________________________________
This e-mail has been scanned for viruses by MCI's Internet Managed
Scanning Services - powered by MessageLabs. For further information
visit http://www.mci.com
------------------------------------------------------------------------------
vRanger cuts backup time in half-while increasing security.
With the market-leading solution for virtual backup and recovery,
you get blazing-fast, flexible, and affordable data protection.
Download your free trial now.
http://p.sf.net/sfu/quest-d2dcopy1
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
**********************************************************************
Any personal or sensitive information contained in this email and
attachments must be handled in accordance with the Victorian Information
Privacy Act 2000, the Health Records Act 2001 or the Privacy Act 1988
(Commonwealth), as applicable.
This email, including all attachments, is confidential. If you are not the
intended recipient, you must not disclose, distribute, copy or use the
information contained in this email or attachments. Any confidentiality or
privilege is not waived or lost because this email has been sent to you in
error. If you have received it in error, please let us know by reply
email, delete it from your system and destroy any copies.
**********************************************************************
------------------------------------------------------------------------------
vRanger cuts backup time in half-while increasing security.
With the market-leading solution for virtual backup and recovery,
you get blazing-fast, flexible, and affordable data protection.
Download your free trial now.
http://p.sf.net/sfu/quest-d2dcopy1
_______________________________________________
qooxdoo-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel