]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Merge branch '1.1.x' of gitorious.org:statusnet/mainline into 1.1.x
authorEvan Prodromou <evan@status.net>
Wed, 17 Oct 2012 14:10:12 +0000 (10:10 -0400)
committerEvan Prodromou <evan@status.net>
Wed, 17 Oct 2012 14:10:12 +0000 (10:10 -0400)
plugins/ClientSideShorten/ClientSideShortenPlugin.php
plugins/InfiniteScroll/InfiniteScrollPlugin.php
plugins/InfiniteScroll/infinitescroll.js

index 6379acd3340ceda95d016e74e6ed8d2335b55bc6..cc109292318a06d3a04ee1191ad649d58380dea7 100644 (file)
@@ -55,7 +55,7 @@ class ClientSideShortenPlugin extends Plugin
             $user = common_current_user();
             $action->inlineScript('var maxNoticeLength = ' . User_urlshortener_prefs::maxNoticeLength($user));
             $action->inlineScript('var maxUrlLength = ' . User_urlshortener_prefs::maxUrlLength($user));
-            $action->script('plugins/ClientSideShorten/shorten.js');
+            $action->script($this->path('shorten.js'));
         }
     }
 
index 376d88abb0add3a770900598e5f78c3c67c47cbe..cec1a5352473f3cb0679e355ff3c55033aa2cab0 100644 (file)
@@ -33,6 +33,9 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
 
 class InfiniteScrollPlugin extends Plugin
 {
+
+    public $on_next_only = false;
+
     function __construct()
     {
         parent::__construct();
@@ -41,6 +44,7 @@ class InfiniteScrollPlugin extends Plugin
     function onEndShowScripts($action)
     {
         $action->inlineScript('var infinite_scroll_on_next_only = ' . ($this->on_next_only?'true':'false') . ';');
+        $action->inlineScript('var ajax_loader_url = "' . ($this->path('ajax-loader.gif')) . '";');
         $action->script($this->path('jquery.infinitescroll.js'));
         $action->script($this->path('infinitescroll.js'));
     }
index f28c90a808fbc20c3cdf4ee5a101fd2f0a7feb02..6fcf098dfe6e169aa99e6a2eb5261c723901311d 100644 (file)
@@ -9,7 +9,7 @@ jQuery(document).ready(function($){
                       'body#showfavorites li.nav_next a,'+
                       'body#showgroup li.nav_next a,'+
                       'body#favorited li.nav_next a',
-    loadingImg      : $('address .url')[0].href+'plugins/InfiniteScroll/ajax-loader.gif',
+    loadingImg      : ajax_loader_url,
     text            : "<em>Loading the next set of posts...</em>",
     donetext        : "<em>Congratulations, you\'ve reached the end of the Internet.</em>",
     navSelector     : "#pagination",