Changeset 36964
- Timestamp:
- 03/10/2016 10:36:25 PM (9 years ago)
- Location:
- trunk/src
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/about.php
r36171 r36964 140 140 ); 141 141 142 $plugin_link = '<a href="' . esc_url( add_query_arg( $url_args, network_admin_url( 'plugin-install.php' ) ) ) . '" class="thickbox ">WordPress REST API</a>';142 $plugin_link = '<a href="' . esc_url( add_query_arg( $url_args, network_admin_url( 'plugin-install.php' ) ) ) . '" class="thickbox open-plugin-details-modal">WordPress REST API</a>'; 143 143 } else { 144 144 $plugin_link = '<a href="https://wordpress.org/plugins/rest-api">WordPress REST API</a>'; -
trunk/src/wp-admin/css/common.css
r36959 r36964 2815 2815 } 2816 2816 2817 /* only on these screens */ 2818 .about-php #TB_closeWindowButton, 2819 .plugin-install-php #TB_closeWindowButton, 2820 .import-php #TB_closeWindowButton, 2821 .plugins-php #TB_closeWindowButton, 2822 .update-core-php #TB_closeWindowButton, 2823 .index-php #TB_closeWindowButton { 2824 left: auto; 2825 right: -30px; 2826 color: #eee; 2827 } 2828 2829 2830 body.about-php #TB_closeWindowButton:hover, 2831 body.about-php #TB_closeWindowButton:focus, 2832 body.plugin-install-php #TB_closeWindowButton:hover, 2833 body.plugin-install-php #TB_closeWindowButton:focus, 2834 body.import-php #TB_closeWindowButton:hover, 2835 body.import-php #TB_closeWindowButton:focus, 2836 body.plugins-php #TB_closeWindowButton:hover, 2837 body.plugins-php #TB_closeWindowButton:focus, 2838 body.update-core-php #TB_closeWindowButton:hover, 2839 body.update-core-php #TB_closeWindowButton:focus, 2840 body.index-php #TB_closeWindowButton:hover, 2841 body.index-php #TB_closeWindowButton:focus { 2842 color: #00a0d2; 2843 outline: none; 2844 -webkit-box-shadow: none; 2845 box-shadow: none; 2846 } 2847 2817 2848 body.about-php .tb-close-icon, 2818 2849 body.plugin-install-php .tb-close-icon, … … 2821 2852 body.update-core-php .tb-close-icon, 2822 2853 body.index-php .tb-close-icon { 2823 left: auto; 2824 right: -30px; 2825 color: #eee; 2826 -webkit-transition: color .1s ease-in-out, background .1s ease-in-out; 2827 transition: color .1s ease-in-out, background .1s ease-in-out; 2828 } 2829 2830 body.about-php #TB_closeWindowButton:focus, 2831 body.about-php #TB_closeWindowButton:focus .tb-close-icon, 2832 body.about-php .tb-close-icon:focus, 2833 body.about-php .tb-close-icon:hover, 2834 body.plugin-install-php #TB_closeWindowButton:focus, 2835 body.plugin-install-php #TB_closeWindowButton:focus .tb-close-icon, 2836 body.plugin-install-php .tb-close-icon:focus, 2837 body.plugin-install-php .tb-close-icon:hover, 2838 body.import-php #TB_closeWindowButton:focus, 2839 body.import-php #TB_closeWindowButton:focus .tb-close-icon, 2840 body.import-php .tb-close-icon:focus, 2841 body.import-php .tb-close-icon:hover, 2842 body.plugins-php #TB_closeWindowButton:focus, 2843 body.plugins-php #TB_closeWindowButton:focus .tb-close-icon, 2844 body.plugins-php .tb-close-icon:focus, 2845 body.plugins-php .tb-close-icon:hover, 2846 body.update-core-php #TB_closeWindowButton:focus, 2847 body.update-core-php #TB_closeWindowButton:focus .tb-close-icon, 2848 body.update-core-php .tb-close-icon:focus, 2849 body.update-core-php .tb-close-icon:hover, 2850 body.index-php #TB_closeWindowButton:focus, 2851 body.index-php #TB_closeWindowButton:focus .tb-close-icon, 2852 body.index-php .tb-close-icon:focus, 2853 body.index-php .tb-close-icon:hover { 2854 color: #00a0d2; 2855 outline: none; 2856 -webkit-box-shadow: none; 2857 box-shadow: none; 2858 } 2859 2860 body.about-php .tb-close-icon:before, 2861 body.plugin-install-php .tb-close-icon:before, 2862 body.import-php .tb-close-icon:before, 2863 body.plugins-php .tb-close-icon:before, 2864 body.update-core-php .tb-close-icon:before, 2865 body.index-php .tb-close-icon:before { 2854 display: none; 2855 } 2856 2857 body.about-php #TB_closeWindowButton:after, 2858 body.plugin-install-php #TB_closeWindowButton:after, 2859 body.import-php #TB_closeWindowButton:after, 2860 body.plugins-php #TB_closeWindowButton:after, 2861 body.update-core-php #TB_closeWindowButton:after, 2862 body.index-php #TB_closeWindowButton:after { 2866 2863 content: "\f335"; 2867 font-size: 32px; 2864 font: normal 32px/29px 'dashicons'; 2865 speak: none; 2866 -webkit-font-smoothing: antialiased; 2867 -moz-osx-font-smoothing: grayscale; 2868 2868 } 2869 2869 2870 2870 /* move plugin install close icon to top on narrow screens */ 2871 2871 @media screen and ( max-width: 830px ) { 2872 body.about-php .tb-close-icon,2873 body.plugin-install-php .tb-close-icon,2874 body.import-php .tb-close-icon,2875 body.plugins-php .tb-close-icon,2876 body.update-core-php .tb-close-icon,2877 body.index-php .tb-close-icon {2872 body.about-php #TB_closeWindowButton, 2873 body.plugin-install-php #TB_closeWindowButton, 2874 body.import-php #TB_closeWindowButton, 2875 body.plugins-php #TB_closeWindowButton, 2876 body.update-core-php #TB_closeWindowButton, 2877 body.index-php #TB_closeWindowButton { 2878 2878 right: 0; 2879 2879 top: -30px; -
trunk/src/wp-admin/import.php
r36653 r36964 102 102 if ( is_main_site() ) { 103 103 $action = '<a href="' . esc_url( network_admin_url( 'plugin-install.php?tab=plugin-information&plugin=' . $plugin_slug . 104 '&from=import&TB_iframe=true&width=600&height=550' ) ) . '" class="thickbox " title="' .104 '&from=import&TB_iframe=true&width=600&height=550' ) ) . '" class="thickbox open-plugin-details-modal" title="' . 105 105 esc_attr__('Install importer') . '">' . $data[0] . '</a>'; 106 106 } else { -
trunk/src/wp-admin/includes/class-wp-plugin-install-list-table.php
r36581 r36964 477 477 478 478 /* translators: 1: Plugin name and version. */ 479 $action_links[] = '<a href="' . esc_url( $details_link ) . '" class="thickbox " aria-label="' . esc_attr( sprintf( __( 'More information about %s' ), $name ) ) . '" data-title="' . esc_attr( $name ) . '">' . __( 'More Details' ) . '</a>';479 $action_links[] = '<a href="' . esc_url( $details_link ) . '" class="thickbox open-plugin-details-modal" aria-label="' . esc_attr( sprintf( __( 'More information about %s' ), $name ) ) . '" data-title="' . esc_attr( $name ) . '">' . __( 'More Details' ) . '</a>'; 480 480 481 481 if ( !empty( $plugin['icons']['svg'] ) ) { … … 505 505 <div class="name column-name"> 506 506 <h3> 507 <a href="<?php echo esc_url( $details_link ); ?>" class="thickbox ">507 <a href="<?php echo esc_url( $details_link ); ?>" class="thickbox open-plugin-details-modal"> 508 508 <?php echo $title; ?> 509 509 <img src="<?php echo esc_attr( $plugin_icon_url ) ?>" class="plugin-icon" alt=""> -
trunk/src/wp-admin/includes/class-wp-plugins-list-table.php
r36830 r36964 743 743 // Details link using API info, if available 744 744 if ( isset( $plugin_data['slug'] ) && current_user_can( 'install_plugins' ) ) { 745 $plugin_meta[] = sprintf( '<a href="%s" class="thickbox " aria-label="%s" data-title="%s">%s</a>',745 $plugin_meta[] = sprintf( '<a href="%s" class="thickbox open-plugin-details-modal" aria-label="%s" data-title="%s">%s</a>', 746 746 esc_url( network_admin_url( 'plugin-install.php?tab=plugin-information&plugin=' . $plugin_data['slug'] . 747 747 '&TB_iframe=true&width=600&height=550' ) ), -
trunk/src/wp-admin/includes/dashboard.php
r36878 r36964 1246 1246 $ilink = wp_nonce_url('plugin-install.php?tab=plugin-information&plugin=' . $slug, 'install-plugin_' . $slug) . '&TB_iframe=true&width=600&height=800'; 1247 1247 echo '<li class="dashboard-news-plugin"><span>' . __( 'Popular Plugin' ) . ':</span> ' . esc_html( $raw_title ) . 1248 ' <a href="' . $ilink . '" class="thickbox " aria-label="' .1248 ' <a href="' . $ilink . '" class="thickbox open-plugin-details-modal" aria-label="' . 1249 1249 /* translators: %s: plugin name */ 1250 1250 esc_attr( sprintf( __( 'Install %s' ), $raw_title ) ) . '">(' . __( 'Install' ) . ')</a></li>'; -
trunk/src/wp-admin/includes/update.php
r36850 r36964 340 340 if ( ! current_user_can( 'update_plugins' ) ) { 341 341 /* translators: 1: plugin name, 2: details URL, 3: accessibility text, 4: version number */ 342 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox " aria-label="%3$s">View version %4$s details</a>.' ),342 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox open-plugin-details-modal" aria-label="%3$s">View version %4$s details</a>.' ), 343 343 $plugin_name, 344 344 esc_url( $details_url ), … … 349 349 } elseif ( empty( $r->package ) ) { 350 350 /* translators: 1: plugin name, 2: details URL, 3: accessibility text, 4: version number */ 351 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox " aria-label="%3$s">View version %4$s details</a>. <em>Automatic update is unavailable for this plugin.</em>' ),351 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox open-plugin-details-modal" aria-label="%3$s">View version %4$s details</a>. <em>Automatic update is unavailable for this plugin.</em>' ), 352 352 $plugin_name, 353 353 esc_url( $details_url ), … … 358 358 } else { 359 359 /* translators: 1: plugin name, 2: details URL, 3: accessibility text, 4: version number, 5: update URL, 6: accessibility text */ 360 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox " aria-label="%3$s">View version %4$s details</a> or <a href="%5$s" class="update-link" aria-label="%6$s">update now</a>.' ),360 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox open-plugin-details-modal" aria-label="%3$s">View version %4$s details</a> or <a href="%5$s" class="update-link" aria-label="%6$s">update now</a>.' ), 361 361 $plugin_name, 362 362 esc_url( $details_url ), … … 470 470 if ( ! current_user_can('update_themes') ) { 471 471 /* translators: 1: theme name, 2: details URL, 3: accessibility text, 4: version number */ 472 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox " aria-label="%3$s">View version %4$s details</a>.'),472 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox open-plugin-details-modal" aria-label="%3$s">View version %4$s details</a>.'), 473 473 $theme_name, 474 474 esc_url( $details_url ), … … 479 479 } elseif ( empty( $r['package'] ) ) { 480 480 /* translators: 1: theme name, 2: details URL, 3: accessibility text, 4: version number */ 481 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox " aria-label="%3$s">View version %4$s details</a>. <em>Automatic update is unavailable for this theme.</em>' ),481 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox open-plugin-details-modal" aria-label="%3$s">View version %4$s details</a>. <em>Automatic update is unavailable for this theme.</em>' ), 482 482 $theme_name, 483 483 esc_url( $details_url ), … … 488 488 } else { 489 489 /* translators: 1: theme name, 2: details URL, 3: accessibility text, 4: version number, 5: update URL, 6: accessibility text */ 490 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox " aria-label="%3$s">View version %4$s details</a> or <a href="%5$s" class="update-link" aria-label="%6$s">update now</a>.' ),490 printf( __( 'There is a new version of %1$s available. <a href="%2$s" class="thickbox open-plugin-details-modal" aria-label="%3$s">View version %4$s details</a> or <a href="%5$s" class="update-link" aria-label="%6$s">update now</a>.' ), 491 491 $theme_name, 492 492 esc_url( $details_url ), -
trunk/src/wp-admin/js/plugin-install.js
r36286 r36964 1 /* global plugininstallL10n, tb_click */1 /* global plugininstallL10n, tb_click, tb_remove */ 2 2 3 3 /* Plugin Browser Thickbox related JS*/ 4 4 var tb_position; 5 5 jQuery( document ).ready( function( $ ) { 6 7 var tbWindow, 8 $focusedBefore, 9 $iframeBody, 10 $tabbables, 11 $firstTabbable, 12 $lastTabbable; 13 6 14 tb_position = function() { 7 var tbWindow = $( '#TB_window' ), 8 width = $( window ).width(), 15 var width = $( window ).width(), 9 16 H = $( window ).height() - ( ( 792 < width ) ? 60 : 20 ), 10 17 W = ( 792 < width ) ? 772 : width - 20; 18 19 tbWindow = $( '#TB_window' ); 11 20 12 21 if ( tbWindow.length ) { … … 39 48 }); 40 49 41 $( '.plugin-card, .plugins .plugin-version-author-uri' ).on( 'click', 'a.thickbox', function( e ) { 50 /* 51 * Custom events: when a Thickbox iframe has loaded and when the Thickbox 52 * modal gets removed from the DOM. 53 */ 54 $( 'body' ) 55 .on( 'thickbox:iframe:loaded', tbWindow, function() { 56 iframeLoaded(); 57 }) 58 .on( 'thickbox:removed', function() { 59 // Set focus back to the element that opened the modal dialog. 60 // Note: IE 8 would need this wrapped in a fake setTimeout `0`. 61 $focusedBefore.focus(); 62 }); 63 64 function iframeLoaded() { 65 var $iframe = tbWindow.find( '#TB_iframeContent' ); 66 67 // Get the iframe body. 68 $iframeBody = $iframe.contents().find( 'body' ); 69 70 // Get the tabbable elements and handle the keydown event on first load. 71 handleTabbables(); 72 73 // Set initial focus on the "Close" button. 74 $firstTabbable.focus(); 75 76 /* 77 * When the "Install" button is disabled (e.g. the Plugin is already installed) 78 * then we can't predict where the last focusable element is. We need to get 79 * the tabbable elements and handle the keydown event again and again, 80 * each time the active tab panel changes. 81 */ 82 $( '#plugin-information-tabs a', $iframeBody ).on( 'click', function() { 83 handleTabbables(); 84 }); 85 86 // Close the modal when pressing Escape. 87 $iframeBody.on( 'keydown', function( event ) { 88 if ( 27 !== event.which ) { 89 return; 90 } 91 tb_remove(); 92 }); 93 } 94 95 /* 96 * Get the tabbable elements and detach/attach the keydown event. 97 * Called after the iframe has fully loaded so we have all the elements we need. 98 * Called again each time a Tab gets clicked. 99 * @todo Consider to implement a WordPress general utility for this and don't use jQuery UI. 100 */ 101 function handleTabbables() { 102 var $firstAndLast; 103 // Get all the tabbable elements. 104 $tabbables = $( ':tabbable', $iframeBody ); 105 // Our first tabbable element is always the "Close" button. 106 $firstTabbable = tbWindow.find( '#TB_closeWindowButton' ); 107 // Get the last tabbable element. 108 $lastTabbable = $tabbables.last(); 109 // Make a jQuery collection. 110 $firstAndLast = $firstTabbable.add( $lastTabbable ); 111 // Detach any previously attached keydown event. 112 $firstAndLast.off( 'keydown.wp-plugin-details' ); 113 // Attach again the keydown event on the first and last focusable elements. 114 $firstAndLast.on( 'keydown.wp-plugin-details', function( event ) { 115 constrainTabbing( event ); 116 }); 117 } 118 119 // Constrain tabbing within the plugin modal dialog. 120 function constrainTabbing( event ) { 121 if ( 9 !== event.which ) { 122 return; 123 } 124 125 if ( $lastTabbable[0] === event.target && ! event.shiftKey ) { 126 event.preventDefault(); 127 $firstTabbable.focus(); 128 } else if ( $firstTabbable[0] === event.target && event.shiftKey ) { 129 event.preventDefault(); 130 $lastTabbable.focus(); 131 } 132 } 133 134 // Open the Plugin details modal. 135 $( '.thickbox.open-plugin-details-modal' ).on( 'click', function( e ) { 136 // The `data-title` attribute is used only in the Plugin screens. 137 var title = $( this ).data( 'title' ) ? plugininstallL10n.plugin_information + ' ' + $( this ).data( 'title' ) : plugininstallL10n.plugin_modal_label; 138 42 139 e.preventDefault(); 43 140 e.stopPropagation(); 44 141 142 // Store the element that has focus before opening the modal dialog, i.e. the control which opens it. 143 $focusedBefore = $( this ); 144 45 145 tb_click.call(this); 46 146 47 $('#TB_title').css({'background-color':'#23282d','color':'#cfcfcf'}); 48 $('#TB_ajaxWindowTitle').html( '<strong>' + plugininstallL10n.plugin_information + '</strong> ' + $(this).data( 'title' ) ); 49 $('#TB_iframeContent').attr( 'title', plugininstallL10n.plugin_information + ' ' + $(this).data( 'title' ) ); 50 $('#TB_closeWindowButton').focus(); 147 // Set ARIA role and ARIA label. 148 tbWindow.attr({ 149 'role': 'dialog', 150 'aria-label': plugininstallL10n.plugin_modal_label 151 }); 152 153 // Set title attribute on the iframe. 154 tbWindow.find( '#TB_iframeContent' ).attr( 'title', title ); 51 155 }); 52 156 -
trunk/src/wp-admin/update-core.php
r36477 r36964 285 285 /* translators: 1: Plugin name 2: Plugin version */ 286 286 $details_text = sprintf( __( 'View %1$s version %2$s details.' ), $details_name, $plugin_data->update->new_version ); 287 $details = sprintf( '<a href="%1$s" class="thickbox ">%2$s</a>', esc_url( $details_url ), $details_text );287 $details = sprintf( '<a href="%1$s" class="thickbox open-plugin-details-modal">%2$s</a>', esc_url( $details_url ), $details_text ); 288 288 $checkbox_id = "checkbox_" . md5( $plugin_data->Name ); 289 289 ?> -
trunk/src/wp-includes/js/thickbox/thickbox.css
r36904 r36964 44 44 } 45 45 46 #TB_closeAjaxWindow { 47 float: right; 48 } 49 50 #TB_closeAjaxWindow a { 51 text-decoration: none; 46 #TB_closeWindowButton { 47 position: absolute; 48 left: auto; 49 right: 0; 50 width: 29px; 51 height: 29px; 52 border: 0; 53 padding: 0; 54 background: none; 55 cursor: pointer; 56 outline: none; 57 -webkit-transition: color .1s ease-in-out, background .1s ease-in-out; 58 transition: color .1s ease-in-out, background .1s ease-in-out; 52 59 } 53 60 … … 116 123 117 124 .tb-close-icon { 125 display: block; 118 126 color: #666; 119 127 text-align: center; … … 134 142 } 135 143 136 .tb-close-icon:hover { 144 #TB_closeWindowButton:hover .tb-close-icon, 145 #TB_closeWindowButton:focus .tb-close-icon { 137 146 color: #00a0d2; 138 147 } -
trunk/src/wp-includes/js/thickbox/thickbox.js
r35418 r36964 41 41 42 42 function tb_show(caption, url, imageGroup) {//function called when the user clicks on a thickbox link 43 44 var $closeBtn; 43 45 44 46 try { … … 138 140 TB_WIDTH = imageWidth + 30; 139 141 TB_HEIGHT = imageHeight + 60; 140 jQuery("#TB_window").append("<a href='' id='TB_ImageOff'><span class='screen-reader-text'>"+thickboxL10n.close+"</span><img id='TB_Image' src='"+url+"' width='"+imageWidth+"' height='"+imageHeight+"' alt='"+caption+"'/></a>" + "<div id='TB_caption'>"+caption+"<div id='TB_secondLine'>" + TB_imageCount + TB_PrevHTML + TB_NextHTML + "</div></div><div id='TB_closeWindow'>< a href='#' id='TB_closeWindowButton'><span class='screen-reader-text'>"+thickboxL10n.close+"</span><div class='tb-close-icon'></div></a></div>");142 jQuery("#TB_window").append("<a href='' id='TB_ImageOff'><span class='screen-reader-text'>"+thickboxL10n.close+"</span><img id='TB_Image' src='"+url+"' width='"+imageWidth+"' height='"+imageHeight+"' alt='"+caption+"'/></a>" + "<div id='TB_caption'>"+caption+"<div id='TB_secondLine'>" + TB_imageCount + TB_PrevHTML + TB_NextHTML + "</div></div><div id='TB_closeWindow'><button type='button' id='TB_closeWindowButton'><span class='screen-reader-text'>"+thickboxL10n.close+"</span><span class='tb-close-icon'></span></button></div>"); 141 143 142 144 jQuery("#TB_closeWindowButton").click(tb_remove); … … 203 205 jQuery("#TB_iframeContent").remove(); 204 206 if(params['modal'] != "true"){//iframe no modal 205 jQuery("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'>< a href='#' id='TB_closeWindowButton'><span class='screen-reader-text'>"+thickboxL10n.close+"</span><div class='tb-close-icon'></div></a></div></div><iframe frameborder='0' hspace='0' allowTransparency='true' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;' >"+thickboxL10n.noiframes+"</iframe>");207 jQuery("#TB_window").append("<div id='TB_title'><div id='TB_ajaxWindowTitle'>"+caption+"</div><div id='TB_closeAjaxWindow'><button type='button' id='TB_closeWindowButton'><span class='screen-reader-text'>"+thickboxL10n.close+"</span><span class='tb-close-icon'></span></button></div></div><iframe frameborder='0' hspace='0' allowtransparency='true' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;' >"+thickboxL10n.noiframes+"</iframe>"); 206 208 }else{//iframe modal 207 209 jQuery("#TB_overlay").unbind(); 208 jQuery("#TB_window").append("<iframe frameborder='0' hspace='0' allow Transparency='true' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;'>"+thickboxL10n.noiframes+"</iframe>");210 jQuery("#TB_window").append("<iframe frameborder='0' hspace='0' allowtransparency='true' src='"+urlNoQuery[0]+"' id='TB_iframeContent' name='TB_iframeContent"+Math.round(Math.random()*1000)+"' onload='tb_showIframe()' style='width:"+(ajaxContentW + 29)+"px;height:"+(ajaxContentH + 17)+"px;'>"+thickboxL10n.noiframes+"</iframe>"); 209 211 } 210 212 }else{// not an iframe, ajax … … 260 262 } 261 263 264 $closeBtn = jQuery( '#TB_closeWindowButton' ); 265 /* 266 * If the native Close button icon is visible, move focus on the button 267 * (e.g. in the Network Admin Themes screen). 268 * In other admin screens is hidden and replaced by a different icon. 269 */ 270 if ( $closeBtn.find( '.tb-close-icon' ).is( ':visible' ) ) { 271 $closeBtn.focus(); 272 } 273 262 274 } catch(e) { 263 275 //nothing here … … 274 286 jQuery("#TB_imageOff").unbind("click"); 275 287 jQuery("#TB_closeWindowButton").unbind("click"); 276 jQuery("#TB_window").fadeOut("fast",function(){jQuery('#TB_window,#TB_overlay,#TB_HideSelect').trigger("tb_unload").unbind().remove();}); 288 jQuery( '#TB_window' ).fadeOut( 'fast', function() { 289 jQuery( '#TB_window, #TB_overlay, #TB_HideSelect' ).trigger( 'tb_unload' ).unbind().remove(); 290 jQuery( 'body' ).trigger( 'thickbox:removed' ); 291 }); 277 292 jQuery( 'body' ).removeClass( 'modal-open' ); 278 293 jQuery("#TB_load").remove(); -
trunk/src/wp-includes/script-loader.php
r36884 r36964 581 581 ) ); 582 582 583 $scripts->add( 'plugin-install', "/wp-admin/js/plugin-install$suffix.js", array( 'jquery', ' thickbox' ), false, 1 );583 $scripts->add( 'plugin-install', "/wp-admin/js/plugin-install$suffix.js", array( 'jquery', 'jquery-ui-core', 'thickbox' ), false, 1 ); 584 584 did_action( 'init' ) && $scripts->localize( 'plugin-install', 'plugininstallL10n', array( 585 'plugin_information' => __('Plugin Information:'), 585 'plugin_information' => __( 'Plugin:' ), 586 'plugin_modal_label' => __( 'Plugin details' ), 586 587 'ays' => __('Are you sure you want to install this plugin?') 587 588 ) );
Note: See TracChangeset
for help on using the changeset viewer.