From 721989b67b60d23534f15824996113a10c512f74 Mon Sep 17 00:00:00 2001 From: rolux Date: Wed, 30 May 2012 19:22:24 +0200 Subject: [PATCH] cleanup --- source/Ox.UI/js/List/List.js | 25 ++++++++++++------------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/source/Ox.UI/js/List/List.js b/source/Ox.UI/js/List/List.js index 7a3b0d89..69825c2d 100644 --- a/source/Ox.UI/js/List/List.js +++ b/source/Ox.UI/js/List/List.js @@ -272,12 +272,12 @@ Ox.List = function(options, self) { } else { arr = [pos]; if (Ox.min(self.selected) < pos) { - for (i = pos - 1; i >= 0; i--) { - if (isSelected(i)) { - break; - } - arr.push(i); - } + for (i = pos - 1; i >= 0; i--) { + if (isSelected(i)) { + break; + } + arr.push(i); + } } if (Ox.max(self.selected) > pos) { for (i = pos + 1; i < len; i++) { @@ -1462,7 +1462,7 @@ Ox.List = function(options, self) { updatePositions(); emptyFirstPage(); fillFirstPage(); - } + }; /*@ closePreview to be called when preview is closed externally @@ -1575,7 +1575,8 @@ Ox.List = function(options, self) { } emptyFirstPage(); fillFirstPage(); - } + }; + /*@ scrollToSelection scroll list to current selection () -> returns List Element @@ -1622,8 +1623,7 @@ Ox.List = function(options, self) { fillFirstPage(); } return that; - } - + }; /*@ sort sort @@ -1632,7 +1632,7 @@ Ox.List = function(options, self) { // but, fixme: better function name that.sort = function() { updateSort(); - } + }; /*@ sortList sort list @@ -1651,7 +1651,7 @@ Ox.List = function(options, self) { that.triggerEvent('sort', self.options.sort[0]); } return that; - } + }; /*@ value get/set list value @@ -1668,7 +1668,6 @@ Ox.List = function(options, self) { var pos = Ox.isNumber(id) ? id : getPositionById(id), $item = self.$items[pos], data = $item ? $item.options('data') : {}; - //Ox.print('List', 'that.value id key value pos', id, key, value, pos) if (arguments.length == 1) { return data; } else if (arguments.length == 2) {