diff --git src/wp-admin/js/updates.js src/wp-admin/js/updates.js
index 233714f589..420d277e28 100644
|
|
|
|
| 373 | 373 | |
| 374 | 374 | if ( 'plugins' === pagenow || 'plugins-network' === pagenow ) { |
| 375 | 375 | $updateRow = $( 'tr[data-plugin="' + args.plugin + '"]' ); |
| | 376 | $updateRow.removeClass( 'update' ).addClass( 'updating' ); |
| 376 | 377 | $message = $updateRow.find( '.update-message' ).removeClass( 'notice-error' ).addClass( 'updating-message notice-warning' ).find( 'p' ); |
| 377 | 378 | message = wp.updates.l10n.pluginUpdatingLabel.replace( '%s', $updateRow.find( '.plugin-title strong' ).text() ); |
| 378 | 379 | } else if ( 'plugin-install' === pagenow || 'plugin-install-network' === pagenow ) { |
| … |
… |
|
| 888 | 889 | |
| 889 | 890 | // Add a plugin update row if it doesn't exist yet. |
| 890 | 891 | if ( ! $pluginUpdateRow.length ) { |
| 891 | | $plugin.addClass( 'update' ).after( |
| | 892 | $plugin.removeClass( 'updating' ).addClass( 'update' ).after( |
| 892 | 893 | pluginUpdateRow( { |
| 893 | 894 | slug: response.slug, |
| 894 | 895 | plugin: response.plugin || response.slug, |
| … |
… |
|
| 920 | 921 | * decorated with an abort() method. |
| 921 | 922 | */ |
| 922 | 923 | wp.updates.updateTheme = function( args ) { |
| 923 | | var $notice; |
| | 924 | var $updateRow, $message; |
| 924 | 925 | |
| 925 | 926 | args = _.extend( { |
| 926 | 927 | success: wp.updates.updateThemeSuccess, |
| … |
… |
|
| 928 | 929 | }, args ); |
| 929 | 930 | |
| 930 | 931 | if ( 'themes-network' === pagenow ) { |
| 931 | | $notice = $( '[data-slug="' + args.slug + '"]' ).find( '.update-message' ).removeClass( 'notice-error' ).addClass( 'updating-message notice-warning' ).find( 'p' ); |
| 932 | | |
| | 932 | $updateRow = $( '[data-slug="' + args.slug + '"]' ); |
| | 933 | $updateRow.removeClass( 'update' ).addClass( 'updating' ); |
| | 934 | $message = $updateRow.find( '.update-message' ).removeClass( 'notice-error' ).addClass( 'updating-message notice-warning' ).find( 'p' ); |
| 933 | 935 | } else { |
| 934 | | $notice = $( '#update-theme' ).closest( '.notice' ).removeClass( 'notice-large' ); |
| | 936 | $message = $( '#update-theme' ).closest( '.notice' ).removeClass( 'notice-large' ); |
| 935 | 937 | |
| 936 | | $notice.find( 'h3' ).remove(); |
| | 938 | $message.find( 'h3' ).remove(); |
| 937 | 939 | |
| 938 | | $notice = $notice.add( $( '[data-slug="' + args.slug + '"]' ).find( '.update-message' ) ); |
| 939 | | $notice = $notice.addClass( 'updating-message' ).find( 'p' ); |
| | 940 | $message = $message.add( $( '[data-slug="' + args.slug + '"]' ).find( '.update-message' ) ); |
| | 941 | $message = $message.addClass( 'updating-message' ).find( 'p' ); |
| 940 | 942 | } |
| 941 | 943 | |
| 942 | | if ( $notice.html() !== wp.updates.l10n.updating ) { |
| 943 | | $notice.data( 'originaltext', $notice.html() ); |
| | 944 | if ( $message.html() !== wp.updates.l10n.updating ) { |
| | 945 | $message.data( 'originaltext', $message.html() ); |
| 944 | 946 | } |
| 945 | 947 | |
| 946 | 948 | wp.a11y.speak( wp.updates.l10n.updatingMsg, 'polite' ); |
| 947 | | $notice.text( wp.updates.l10n.updating ); |
| | 949 | $message.text( wp.updates.l10n.updating ); |
| 948 | 950 | |
| 949 | 951 | $document.trigger( 'wp-theme-updating', args ); |
| 950 | 952 | |
| … |
… |
|
| 1309 | 1311 | |
| 1310 | 1312 | if ( 'themes-network' === pagenow ) { |
| 1311 | 1313 | if ( ! $updateRow.length ) { |
| 1312 | | $themeRow.addClass( 'update' ).after( |
| | 1314 | $themeRow.removeClass( 'updating' ).addClass( 'update' ).after( |
| 1313 | 1315 | updateRow( { |
| 1314 | 1316 | slug: response.slug, |
| 1315 | 1317 | colspan: $( '#bulk-action-form' ).find( 'thead th:not(.hidden), thead td' ).length, |
| … |
… |
|
| 2065 | 2067 | $itemRow = $checkbox.parents( 'tr' ); |
| 2066 | 2068 | |
| 2067 | 2069 | // Only add update-able items to the update queue. |
| 2068 | | if ( 'update-selected' === bulkAction && ( ! $itemRow.hasClass( 'update' ) || $itemRow.find( 'notice-error' ).length ) ) { |
| | 2070 | if ( 'update-selected' === bulkAction && ( ! $itemRow.hasClass( 'update' ) || $itemRow.find( '.notice.notice-error' ).length ) ) { |
| 2069 | 2071 | |
| 2070 | 2072 | // Un-check the box. |
| 2071 | 2073 | $checkbox.prop( 'checked', false ); |