mirror of
https://github.com/WordPress/WordPress.git
synced 2025-02-22 23:41:38 +01:00
Prevent hotkeys from clicking hidden links -- keeps U and A from both acting as moderated/approved toggles. Now each one just does its own function.
git-svn-id: http://svn.automattic.com/wordpress/trunk@10065 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
6d0ea0e3e9
commit
90ec026142
@ -175,6 +175,8 @@ var wpList = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
ajaxDim: function( e, s ) {
|
ajaxDim: function( e, s ) {
|
||||||
|
if ( $(e).parent().css('display') == 'none' ) // Prevent hidden links from being clicked by hotkeys
|
||||||
|
return false;
|
||||||
var list = this; e = $(e); s = s || {};
|
var list = this; e = $(e); s = s || {};
|
||||||
var cls = wpList.parseClass(e,'dim');
|
var cls = wpList.parseClass(e,'dim');
|
||||||
s = wpList.pre.call( list, e, s, 'dim' );
|
s = wpList.pre.call( list, e, s, 'dim' );
|
||||||
|
@ -77,7 +77,7 @@ function wp_default_scripts( &$scripts ) {
|
|||||||
|
|
||||||
$scripts->add( 'autosave', '/wp-includes/js/autosave.js', array('schedule', 'wp-ajax-response'), '20081110' );
|
$scripts->add( 'autosave', '/wp-includes/js/autosave.js', array('schedule', 'wp-ajax-response'), '20081110' );
|
||||||
|
|
||||||
$scripts->add( 'wp-lists', '/wp-includes/js/wp-lists.js', array('wp-ajax-response'), '20081204' );
|
$scripts->add( 'wp-lists', '/wp-includes/js/wp-lists.js', array('wp-ajax-response'), '20081205' );
|
||||||
$scripts->localize( 'wp-lists', 'wpListL10n', array(
|
$scripts->localize( 'wp-lists', 'wpListL10n', array(
|
||||||
'url' => admin_url('admin-ajax.php')
|
'url' => admin_url('admin-ajax.php')
|
||||||
) );
|
) );
|
||||||
|
Loading…
Reference in New Issue
Block a user