Hi, as you say, you change the selection of your property table within the meantime of setData... Maybe the behaviour you described changes if you first invoke setData and then set the default selection. Without seeing your code it is like fishing in muddy water :)
I think the best idea is to change the selection inside an event listener to the dataChanged event of your property table. Regards, Andreas -----Ursprüngliche Nachricht----- Von: sikd [mailto:[email protected]] Gesendet: Dienstag, 17. November 2009 11:36 An: [email protected] Betreff: [qooxdoo-devel] tableSelectionModel changeSelection bug? I can't deside that is this my fault or is this a bug. Unfortunatelly the code is too long, so I have to give a brief explanation: I have two tables: tableNames, tableProperties. They both have their own tableSelectionModels, for which I append listeners: "changeSelection". When the user select a name from the tableName, the tableProperties change its content to show the "properties" of the selected "name". For this I make a tmpTableData array with the properties and after that I set new datas to the tableModel: tablePropertiesModel.setData(tmpTableData). When the user select a "property" from the tableProperties he/she got the details belongs to the selected property (in another widget, which could be whatever). Everything seems to be perfect, but: When the user selects a "property", the details show up fine. But when after that the user select a "name", the property table changes its content and in the meantime I change the default selection to the first row of the tableProperties. This invoke a changeSelection event in the tableProperty. The problem is, that the appended event listener thinks that the tablePropertyModel has the old rows. So after the <code> tablePropertiesSelectionModel.iterateSelection(function(index) { selectedRowData = (tablePropertiesModel.getRowData(index)) }); </code> the selectedRowData will contain the first row of _previous_ property-list. I hope I could explain it clearly enough. Have anybody an idea what could be the problem? -- View this message in context: http://old.nabble.com/tableSelectionModel-changeSelection-bug--tp26387638p26387638.html Sent from the qooxdoo-devel mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
