summaryrefslogtreecommitdiff
path: root/plugins/Autocomplete/AutocompletePlugin.php
diff options
context:
space:
mode:
authorBrion Vibber <brion@status.net>2010-08-10 15:01:29 -0700
committerBrion Vibber <brion@status.net>2010-08-10 15:01:29 -0700
commit819d33210d298de74b64dc7ead79e9d9b223b12e (patch)
tree902d42087e633b96e12bef699f6c80e7342c9312 /plugins/Autocomplete/AutocompletePlugin.php
parent8f071b2818e8321ea910df612016175f65093402 (diff)
parent08fc6053ec55e911b842fd05dafc5e0c99c4e992 (diff)
Merge branch '0.9.x' into tinymce
Diffstat (limited to 'plugins/Autocomplete/AutocompletePlugin.php')
-rw-r--r--plugins/Autocomplete/AutocompletePlugin.php15
1 files changed, 12 insertions, 3 deletions
diff --git a/plugins/Autocomplete/AutocompletePlugin.php b/plugins/Autocomplete/AutocompletePlugin.php
index d586631a4..b2be365dd 100644
--- a/plugins/Autocomplete/AutocompletePlugin.php
+++ b/plugins/Autocomplete/AutocompletePlugin.php
@@ -22,7 +22,8 @@
* @category Plugin
* @package StatusNet
* @author Craig Andrews <candrews@integralblue.com>
- * @copyright 2009 Craig Andrews http://candrews.integralblue.com
+ * @copyright 2010 Free Software Foundation http://fsf.org
+ * @copyright 2009 Free Software Foundation, Inc http://www.fsf.org
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
* @link http://status.net/
*/
@@ -31,8 +32,6 @@ if (!defined('STATUSNET') && !defined('LACONICA')) {
exit(1);
}
-require_once(INSTALLDIR.'/plugins/Autocomplete/autocomplete.php');
-
class AutocompletePlugin extends Plugin
{
function __construct()
@@ -40,6 +39,16 @@ class AutocompletePlugin extends Plugin
parent::__construct();
}
+ function onAutoload($cls)
+ {
+ switch ($cls)
+ {
+ case 'AutocompleteAction':
+ require_once(INSTALLDIR.'/plugins/Autocomplete/autocomplete.php');
+ return false;
+ }
+ }
+
function onEndShowScripts($action){
if (common_logged_in()) {
$action->script('plugins/Autocomplete/jquery-autocomplete/jquery.autocomplete.pack.js');