. * * @category Plugin * @package StatusNet * @author Craig Andrews * @copyright 2009 Craig Andrews http://candrews.integralblue.com * @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0 * @link http://status.net/ */ if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); } class AutocompletePlugin extends Plugin { function __construct() { parent::__construct(); } function onEndShowScripts($action){ if (common_logged_in()) { $current_user = common_current_user(); $js_string = << var current_user = { id: '$current_user->id' }; EOT; $action->raw($js_string); $action->script('plugins/Autocomplete/jquery-autocomplete/jquery.autocomplete.pack.js'); $action->script('plugins/Autocomplete/Autocomplete.js'); } } function onEndShowStatusNetStyles($action) { if (common_logged_in()) { $action->cssLink('plugins/Autocomplete/jquery-autocomplete/jquery.autocomplete.css'); } } } ?>