Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/diaspora/diaspora.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/public
diff options
context:
space:
mode:
authorRaphael Sofaer <raphael@joindiaspora.com>2011-07-30 04:01:45 +0400
committerRaphael Sofaer <raphael@joindiaspora.com>2011-07-30 04:01:45 +0400
commit0873ad5828dd515ea01adb67647dc749d51b348c (patch)
treefbb4d94f4b3c8e651fecf8ed0c86591d1bd7a756 /public
parentf9bf34a73ecef18c73ec191b813d66b3c60d8fed (diff)
Test and fix contacts index page
Diffstat (limited to 'public')
-rw-r--r--public/javascripts/widgets/infinite-scroll.js25
1 files changed, 14 insertions, 11 deletions
diff --git a/public/javascripts/widgets/infinite-scroll.js b/public/javascripts/widgets/infinite-scroll.js
index 86e0548c7..721c54758 100644
--- a/public/javascripts/widgets/infinite-scroll.js
+++ b/public/javascripts/widgets/infinite-scroll.js
@@ -29,21 +29,24 @@
this.reInitialize = function() {
self.clear();
- self.initialize();
+ self.initialize();
};
this.initialize = function() {
if($('#main_stream').length !== 0){
- $('#main_stream').infinitescroll(this.options, function() {
- Diaspora.widgets.publish("stream/scrolled");
- });
- } else if($('#people_stream.contacts').length !== 0){
- $("#people_stream.contacts").infinitescroll($.extend(self.options, {
- navSelector : ".pagination",
- nextSelector : ".next_page",
- }), function() {
- Diaspora.widgets.publish("stream/scrolled");
- });
+ $('#main_stream').infinitescroll(this.options, function() {
+ Diaspora.widgets.publish("stream/scrolled");
+ });
+ } else if($('#people_stream').length !== 0){
+ $("#people_stream").infinitescroll($.extend(self.options, {
+ navSelector : ".pagination",
+ nextSelector : ".next_page",
+ pathParse : function( pathStr, nextPage){
+ return pathStr.replace("page=2", "page=" + nextPage);
+ }
+ }), function() {
+ Diaspora.widgets.publish("stream/scrolled");
+ });
}
};