]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-admin/js/customize-controls.js
Wordpress 3.6
[autoinstalls/wordpress.git] / wp-admin / js / customize-controls.js
index 96f776744fe76732b7990b8b974f9b23a5af78c3..01fffbac171346482d35c2c9177dde439b2112cc 100644 (file)
                        api.state = state;
                }());
 
                        api.state = state;
                }());
 
-               // Temporary accordion code.
-               $('.customize-section-title').bind('click keydown', function( event ) {
-
-                       if ( event.type === 'keydown' &&  13 !== event.which ) // enter
-                                       return;
-
-                       var clicked = $( this ).parents( '.customize-section' );
-
-                       if ( clicked.hasClass('cannot-expand') )
-                               return;
-
-                       // Scroll up if on #customize-section-title_tagline
-                       if ('customize-section-title_tagline' === clicked.attr('id'))
-                               $('.wp-full-overlay-sidebar-content').scrollTop(0);
-
-                       $( '.customize-section' ).not( clicked ).removeClass( 'open' );
-                       clicked.toggleClass( 'open' );
-                       event.preventDefault();
-               });
-
                // Button bindings.
                $('#save').click( function( event ) {
                        previewer.save();
                // Button bindings.
                $('#save').click( function( event ) {
                        previewer.save();
                        event.preventDefault();
                });
 
                        event.preventDefault();
                });
 
+               $('.upload-dropzone a.upload').keydown( function( event ) {
+                       if ( 13 === event.which ) // enter
+                               this.click();
+               });
+
                $('.collapse-sidebar').on( 'click keydown', function( event ) {
                        if ( event.type === 'keydown' &&  13 !== event.which ) // enter
                                return;
                $('.collapse-sidebar').on( 'click keydown', function( event ) {
                        if ( event.type === 'keydown' &&  13 !== event.which ) // enter
                                return;