InfiniteScroll#options doesn't need to be a function
This commit is contained in:
parent
89ec768d06
commit
abde3244b5
1 changed files with 3 additions and 4 deletions
|
|
@ -5,8 +5,8 @@
|
||||||
|
|
||||||
(function() {
|
(function() {
|
||||||
var InfiniteScroll = function() { };
|
var InfiniteScroll = function() { };
|
||||||
InfiniteScroll.prototype.options = function(){
|
InfiniteScroll.prototype.options =
|
||||||
return {
|
{
|
||||||
navSelector : "#pagination",
|
navSelector : "#pagination",
|
||||||
nextSelector : ".paginate",
|
nextSelector : ".paginate",
|
||||||
itemSelector : ".stream_element",
|
itemSelector : ".stream_element",
|
||||||
|
|
@ -21,7 +21,6 @@
|
||||||
loadingText: "",
|
loadingText: "",
|
||||||
loadingImg: '/images/ajax-loader.gif'
|
loadingImg: '/images/ajax-loader.gif'
|
||||||
};
|
};
|
||||||
};
|
|
||||||
|
|
||||||
InfiniteScroll.prototype.reInitialize = function(){
|
InfiniteScroll.prototype.reInitialize = function(){
|
||||||
this.clear();
|
this.clear();
|
||||||
|
|
@ -30,7 +29,7 @@
|
||||||
|
|
||||||
InfiniteScroll.prototype.initialize = function(){
|
InfiniteScroll.prototype.initialize = function(){
|
||||||
if($('#main_stream').length !== 0){
|
if($('#main_stream').length !== 0){
|
||||||
$('#main_stream').infinitescroll(this.options(), function() {
|
$('#main_stream').infinitescroll(this.options, function() {
|
||||||
Diaspora.widgets.publish("stream/scrolled");
|
Diaspora.widgets.publish("stream/scrolled");
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue