cleaning up local logging in ui-scroll.js
authorBill Erickson <berick@esilibrary.com>
Mon, 31 Mar 2014 19:38:59 +0000 (15:38 -0400)
committerBill Erickson <berick@esilibrary.com>
Mon, 31 Mar 2014 19:38:59 +0000 (15:38 -0400)
Signed-off-by: Bill Erickson <berick@esilibrary.com>
Open-ILS/web/js/ui/default/staff/services/ui-scroll.js

index a52430f..00f8551 100644 (file)
@@ -52,7 +52,7 @@ angular.module('ui.scroll', []).directive('ngScrollViewport', [
                             return viewport.height() * Math.max(0.1, +$attr.padding || 0.1);
                         };
                         scrollHeight = function(elem) {
-                            console.log(elem[0].scrollHeight, elem[0].document);
+                            //console.log(elem[0].scrollHeight, elem[0].document);
                             if( !elem[0].scrollHeight && !elem[0].document ) {
                                 throw new Error('Could not determine scrollHeight of your viewport; make sure it has a constrained height (not height:auto)');
                             }
@@ -264,7 +264,7 @@ angular.module('ui.scroll', []).directive('ngScrollViewport', [
                         adjustBuffer = function(scrolling, newItems, finalize) {
                             var doAdjustment;
                             doAdjustment = function() {
-                                console.log('top {actual=' + (adapter.topDataPos()) + ' visible from=' + (topVisiblePos()) + ' bottom {visible through=' + (bottomVisiblePos()) + ' actual=' + (adapter.bottomDataPos()) + '}');
+                                //console.log('top {actual=' + (adapter.topDataPos()) + ' visible from=' + (topVisiblePos()) + ' bottom {visible through=' + (bottomVisiblePos()) + ' actual=' + (adapter.bottomDataPos()) + '}');
                                 if (shouldLoadBottom()) {
                                     enqueueFetch(true, scrolling);
                                 } else {
@@ -313,14 +313,14 @@ angular.module('ui.scroll', []).directive('ngScrollViewport', [
                                         if (result.length === 0) {
                                             eof = true;
                                             adapter.bottomPadding(0);
-                                            console.log('appended: requested ' + bufferSize + ' records starting from ' + next + ' recieved: eof');
+                                            //console.log('appended: requested ' + bufferSize + ' records starting from ' + next + ' recieved: eof');
                                         } else {
                                             clipTop();
                                             for (_i = 0, _len = result.length; _i < _len; _i++) {
                                                 item = result[_i];
                                                 newItems.push(insert(++next, item));
                                             }
-                                            console.log('appended: requested ' + bufferSize + ' received ' + result.length + ' buffer size ' + buffer.length + ' first ' + first + ' next ' + next);
+                                            //console.log('appended: requested ' + bufferSize + ' received ' + result.length + ' buffer size ' + buffer.length + ' first ' + first + ' next ' + next);
                                         }
                                         return finalize(scrolling, newItems);
                                     });
@@ -335,13 +335,13 @@ angular.module('ui.scroll', []).directive('ngScrollViewport', [
                                         if (result.length === 0) {
                                             bof = true;
                                             adapter.topPadding(0);
-                                            console.log('prepended: requested ' + bufferSize + ' records starting from ' + (first - bufferSize) + ' recieved: bof');
+                                            //console.log('prepended: requested ' + bufferSize + ' records starting from ' + (first - bufferSize) + ' recieved: bof');
                                         } else {
                                             clipBottom();
                                             for (i = _i = _ref = result.length - 1; _ref <= 0 ? _i <= 0 : _i >= 0; i = _ref <= 0 ? ++_i : --_i) {
                                                 newItems.unshift(insert(--first, result[i]));
                                             }
-                                            console.log('prepended: requested ' + bufferSize + ' received ' + result.length + ' buffer size ' + buffer.length + ' first ' + first + ' next ' + next);
+                                            //console.log('prepended: requested ' + bufferSize + ' received ' + result.length + ' buffer size ' + buffer.length + ' first ' + first + ' next ' + next);
                                         }
                                         return finalize(scrolling, newItems);
                                     });