]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-includes/js/wp-lists.js
Wordpress 2.7.1-scripts
[autoinstalls/wordpress.git] / wp-includes / js / wp-lists.js
index 884f02a6fd2d7732d77fc6510c373378d0faa3c2..128cf157a2047ce8c33ef7e4f84f9eb7725b8004 100644 (file)
@@ -26,7 +26,7 @@ var wpList = {
                var c = [], cl;
                try {
                        cl = $(e).attr('class') || '';
-                       cl = cl.match(new RegExp(t+':[A-Za-z0-9:_=-]+'));
+                       cl = cl.match(new RegExp(t+':[\\S]+'));
                        if ( cl ) { c = cl[0].split(':'); }
                } catch(r) {}
                return c;
@@ -88,6 +88,8 @@ var wpList = {
                        var res = wpAjax.parseAjaxResponse(r, s.response, s.element);
                        if ( !res || res.errors ) { return false; }
 
+                       if ( true === res ) { return true; }
+
                        jQuery.each( res.responses, function() {
                                wpList.add.call( list, this.data, $.extend( {}, s, { // this.firstChild.nodevalue
                                        pos: this.position || 0,
@@ -173,6 +175,8 @@ var wpList = {
        },
 
        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 cls = wpList.parseClass(e,'dim');
                s = wpList.pre.call( list, e, s, 'dim' );