Ticket #20868: 20868.diff
File 20868.diff, 2.2 KB (added by , 12 years ago) |
---|
-
wp-includes/js/customize-base.dev.js
547 547 send: function( id, data ) { 548 548 var message; 549 549 550 data = typeof data === 'undefined' ? {}: data;550 data = typeof data === 'undefined' ? null : data; 551 551 552 552 if ( ! this.url() || ! this.targetWindow() ) 553 553 return; -
wp-includes/js/customize-loader.dev.js
98 98 Loader.close(); 99 99 }); 100 100 101 this.messenger.bind( 'activated', function( location ) { 102 if ( location ) 103 window.location = location; 104 }); 105 101 106 hash = src.split('?')[1]; 102 107 103 108 // Ensure we don't call pushState if the user hit the forward button. -
wp-admin/js/customize-controls.dev.js
684 684 api.state = state; 685 685 }()); 686 686 687 api.bind( 'activated', function() {688 if ( api.settings.url.activated )689 window.location = api.settings.url.activated;690 });691 692 687 // Temporary accordion code. 693 688 $('.customize-section-title').click( function( event ) { 694 689 var clicked = $( this ).parents( '.customize-section' ); … … 728 723 }); 729 724 730 725 // Pass events through to the parent. 731 $.each([ 'saved', 'activated' ], function( i, id ) { 732 api.bind( id, function() { 733 parent.send( id ); 734 }); 726 api.bind( 'saved', function() { 727 parent.send( 'saved' ); 735 728 }); 736 729 730 // When activated, let the loader handle redirecting the page. 731 // If no loader exists, redirect the page ourselves (if a url exists). 732 api.bind( 'activated', function() { 733 if ( parent.targetWindow() ) 734 parent.send( 'activated', api.settings.url.activated ); 735 else if ( api.settings.url.activated ) 736 window.location = api.settings.url.activated; 737 }); 738 737 739 // Initialize the connection with the parent frame. 738 740 parent.send( 'ready' ); 739 741