If you have a consistent set of properties to set each time, then instead
of copying them from the old table to the new one, you could just subclass
the table (or its components) and have the subclass set the property values
that you want. That way, all you need to do is instantiate a new one of
your table subclass.
For the data, you can retrieve the current data with
oldTable.getDataAsMapArray(). If you're deleting a column, you can use that
map array as is, for the new array, as the extra data will just not appear
in the table. If you're adding a column, you can iterate over the map
array, adding the column data for the new column. In either case, you call
newTable.setDataAsMapArray() with your (possibly) altered data array.
Cheers,
Derrell
On Sat, Sep 28, 2013 at 12:31 PM, deniska <den...@gmail.com> wrote:
> Thanks.
>
> In that case I'm thinking perhaps creating a new table, copying all the
> properties except for tableModel and setting tableModel manually with 1
> more
> column.
>
> Would that work, or do I need to copy additional stuff, except for
> properties?
>
>
>
> --
> View this message in context:
> http://qooxdoo.678.n2.nabble.com/Adding-column-to-existing-table-tp7584683p7584687.html
> Sent from the qooxdoo mailing list archive at Nabble.com.
>
>
> ------------------------------------------------------------------------------
> October Webinars: Code for Performance
> Free Intel webinars can help you accelerate application performance.
> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most
> from
> the latest Intel processors and coprocessors. See abstracts and register >
> http://pubads.g.doubleclick.net/gampad/clk?id=60133471&iu=/4140/ostg.clktrk
> _______________________________________________
> qooxdoo-devel mailing list
> qooxdoo-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
>
------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60133471&iu=/4140/ostg.clktrk
_______________________________________________
qooxdoo-devel mailing list
qooxdoo-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel