Index: trunk/extensions/Storyboard/jquery/jquery.ajaxscroll.js |
— | — | @@ -36,7 +36,7 @@ |
37 | 37 | var $me = jQuery( this ); |
38 | 38 | var $sp; |
39 | 39 | var offset = 0; |
40 | | - var lsp = -1; |
| 40 | + var previousScrollPos = -1; |
41 | 41 | |
42 | 42 | $me.css( { |
43 | 43 | "overflow-x": "hidden", |
— | — | @@ -106,22 +106,22 @@ |
107 | 107 | * function if this is the case. |
108 | 108 | */ |
109 | 109 | function handleScrolling() { |
110 | | - var so = $me.scrollTop(); |
| 110 | + var scrollPos = $me.scrollTop(); |
111 | 111 | |
112 | | - if( !window.storyboardBusy && lsp != so ) { |
113 | | - lsp = so; |
| 112 | + if( !window.storyboardBusy && previousScrollPos != scrollPos ) { |
| 113 | + previousScrollPos = scrollPos; |
114 | 114 | var co = $me.offset().top; |
115 | 115 | |
116 | 116 | $sp.find( '> .' + opt.emptyBatchClass ).each( function( i, obj ) { |
117 | | - var $b = jQuery( obj ); |
118 | | - var p = $b.position().top - co; |
| 117 | + var $batchDiv = jQuery( obj ); |
| 118 | + var p = $batchDiv.position().top - co; |
119 | 119 | |
120 | 120 | if ( opt.lBound > p || p > opt.uBound ) { |
121 | 121 | return; |
122 | 122 | } |
123 | 123 | |
124 | 124 | window.storyboardBusy = true; |
125 | | - opt.updateBatch( $b.removeClass( opt.emptyBatchClass ) ); |
| 125 | + opt.updateBatch( $batchDiv.removeClass( opt.emptyBatchClass ) ); |
126 | 126 | }); |
127 | 127 | } |
128 | 128 | |
Index: trunk/extensions/Storyboard/tags/Storyboard/storyboard.js |
— | — | @@ -10,7 +10,7 @@ |
11 | 11 | $( '.storyboard' ).ajaxScroll( { |
12 | 12 | updateBatch: updateStoryboard, |
13 | 13 | maxOffset: 500, |
14 | | - batchSize: 8, |
| 14 | + batchSize: 2, |
15 | 15 | batchNum: 2, // TODO: change to 1. Some issue in the ajaxscroll plugin makesit break when this is the case though. |
16 | 16 | batchClass: "batch", |
17 | 17 | boxClass: "storyboard-box", |
— | — | @@ -24,7 +24,7 @@ |
25 | 25 | 'action': 'query', |
26 | 26 | 'list': 'stories', |
27 | 27 | 'format': 'json', |
28 | | - 'stlimit': 8, |
| 28 | + 'stlimit': 2, |
29 | 29 | 'stlanguage': window.storyboardLanguage |
30 | 30 | }; |
31 | 31 | |
Index: trunk/extensions/Storyboard/api/ApiQueryStories.php |
— | — | @@ -79,12 +79,10 @@ |
80 | 80 | $storyModified = $continueParams[0]; |
81 | 81 | $storyId = intval( $continueParams[1] ); |
82 | 82 | |
83 | | - /* FIXME |
84 | 83 | $this->addWhere( |
85 | | - "story_modified > $storyModified OR " . |
| 84 | + "story_modified < $storyModified OR " . |
86 | 85 | "(story_modified = $storyId AND story_id <= $storyModified)" |
87 | 86 | ); |
88 | | - */ |
89 | 87 | } |
90 | 88 | |
91 | 89 | $stories = $this->select( __METHOD__ ); |