From a3b90fd0cc09d44cb47d20ff9a71b7b1cb4fb2be Mon Sep 17 00:00:00 2001 From: Allan Jardine Date: Tue, 23 Apr 2013 08:49:06 +0100 Subject: [PATCH] New: API methods rows().nodes(), rows().data() and columns().header() - rows().nodes() - Get the TR nodes for the selected rows - rows().data() - Get the data for the selected rows - columns().header() - Get the header cells for the selected columns - This also introduces the `iterator` method to the API instance, which can be used to loop over selected columns / rows, for the context (tables), returning a flat array / API instance. --- media/src/api/api._selectors.js | 14 +++++++------- media/src/api/api.columns.js | 22 +++------------------- media/src/api/api.core.js | 27 +++++++++++++++++++++++++++ media/src/api/api.rows.js | 15 +++++++++++++++ 4 files changed, 52 insertions(+), 26 deletions(-) diff --git a/media/src/api/api._selectors.js b/media/src/api/api._selectors.js index c08beafe..fbb4215a 100644 --- a/media/src/api/api._selectors.js +++ b/media/src/api/api._selectors.js @@ -19,20 +19,20 @@ var _intVal = function ( s ) { var _selector_run = function ( selector, select ) { var - out = [], - a, i, ien, res; + out = [], res, + a, i, ien, j, jen; if ( ! $.isArray( selector ) ) { selector = [ selector ]; } for ( i=0, ien=selector.length ; i