diff options
Diffstat (limited to 'views/default')
-rw-r--r-- | views/default/core/account/login_box.php | 2 | ||||
-rw-r--r-- | views/default/core/account/login_dropdown.php | 11 | ||||
-rw-r--r-- | views/default/core/river/filter.php | 2 | ||||
-rw-r--r-- | views/default/js/admin.php | 2 | ||||
-rw-r--r-- | views/default/js/elgg.php | 7 |
5 files changed, 11 insertions, 13 deletions
diff --git a/views/default/core/account/login_box.php b/views/default/core/account/login_box.php index 40b5f5637..274172bdb 100644 --- a/views/default/core/account/login_box.php +++ b/views/default/core/account/login_box.php @@ -20,7 +20,7 @@ echo elgg_view_module('aside', $title, $body); <script type="text/javascript"> - elgg.register_event_handler('init', 'system', function() { + elgg.register_hook_handler('init', 'system', function() { $('input[name=username]').focus(); }); </script> diff --git a/views/default/core/account/login_dropdown.php b/views/default/core/account/login_dropdown.php index f3f105be1..a1d64a768 100644 --- a/views/default/core/account/login_dropdown.php +++ b/views/default/core/account/login_dropdown.php @@ -1,8 +1,6 @@ <?php /** * Elgg drop-down login form - * - * @todo Forms 1.8: Convert to use elgg_view_form() */ if (elgg_is_logged_in()) { @@ -19,12 +17,11 @@ $body = elgg_view_form('login', array('action' => "{$login_url}action/login"), a <div id="login-dropdown"> <?php echo elgg_view('output/url', array( - 'href' => 'login', + 'href' => 'login#login-dropdown-box', + 'rel' => 'popup', + 'class' => 'elgg-button elgg-button-dropdown', 'text' => elgg_echo('login'), )); echo elgg_view_module('dropdown', '', $body, array('id' => 'login-dropdown-box')); ?> -</div> -<script> - $('#login-dropdown > a').attr('href', '#login-dropdown-box').addClass('elgg-toggler elgg-button elgg-button-dropdown'); -</script>
\ No newline at end of file +</div>
\ No newline at end of file diff --git a/views/default/core/river/filter.php b/views/default/core/river/filter.php index 0df10675c..87380b561 100644 --- a/views/default/core/river/filter.php +++ b/views/default/core/river/filter.php @@ -37,7 +37,7 @@ echo elgg_view('input/dropdown', $params); ?> <?php //@todo JS 1.8: no ?> <script type="text/javascript"> -elgg.register_event_handler('init', 'system', function() { +elgg.register_hook_handler('init', 'system', function() { $('#elgg-river-selector').change(function() { var url = window.location.href; if (window.location.search.length) { diff --git a/views/default/js/admin.php b/views/default/js/admin.php index 15c74d4de..afffe95f0 100644 --- a/views/default/js/admin.php +++ b/views/default/js/admin.php @@ -146,4 +146,4 @@ elgg.admin.moveProfileField = function(e, ui) { }); } -elgg.register_event_handler('init', 'system', elgg.admin.init, 1000);
\ No newline at end of file +elgg.register_hook_handler('init', 'system', elgg.admin.init, 1000);
\ No newline at end of file diff --git a/views/default/js/elgg.php b/views/default/js/elgg.php index 9ddd6907a..018db7967 100644 --- a/views/default/js/elgg.php +++ b/views/default/js/elgg.php @@ -28,7 +28,7 @@ foreach ($model_files as $file) { $libs = array( //libraries 'prototypes', - 'events', + 'hooks', 'security', 'languages', 'ajax', @@ -59,11 +59,12 @@ elgg.security.interval = 5 * 60 * 1000; <?php //@todo make this configurable ?> //Mimic PHP engine boot process //Before the DOM is ready -- note that plugins aren't loaded yet -elgg.trigger_event('boot', 'system'); +elgg.trigger_hook('boot', 'system'); //After the DOM is ready $(function() { - elgg.trigger_event('init', 'system'); + elgg.trigger_hook('init', 'system'); + elgg.trigger_hook('ready', 'system'); }); <?php |