Decrement update count bubbles as plugins/themes are updated, live.

props gcorne, mitchoyoshitaka.
fixes #17703.


git-svn-id: https://develop.svn.wordpress.org/trunk@27280 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Nacin
2014-02-26 06:54:26 +00:00
parent 544b73ec4c
commit 9ddf03c0bb
7 changed files with 114 additions and 5 deletions
+5 -2
View File
@@ -37,7 +37,7 @@ if ( isset($_GET['action']) ) {
$url = 'update.php?action=update-selected&plugins=' . urlencode(implode(',', $plugins));
$nonce = 'bulk-update-plugins';
wp_enqueue_script('jquery');
wp_enqueue_script( 'updates' );
iframe_header();
$upgrader = new Plugin_Upgrader( new Bulk_Plugin_Upgrader_Skin( compact( 'nonce', 'url' ) ) );
@@ -54,6 +54,8 @@ if ( isset($_GET['action']) ) {
$title = __('Update Plugin');
$parent_file = 'plugins.php';
$submenu_file = 'plugins.php';
wp_enqueue_script( 'updates' );
require_once(ABSPATH . 'wp-admin/admin-header.php');
$nonce = 'upgrade-plugin_' . $plugin;
@@ -154,6 +156,7 @@ if ( isset($_GET['action']) ) {
check_admin_referer('upgrade-theme_' . $theme);
wp_enqueue_script( 'customize-loader' );
wp_enqueue_script( 'updates' );
$title = __('Update Theme');
$parent_file = 'themes.php';
@@ -185,7 +188,7 @@ if ( isset($_GET['action']) ) {
$url = 'update.php?action=update-selected-themes&themes=' . urlencode(implode(',', $themes));
$nonce = 'bulk-update-themes';
wp_enqueue_script('jquery');
wp_enqueue_script( 'updates' );
iframe_header();
$upgrader = new Theme_Upgrader( new Bulk_Theme_Upgrader_Skin( compact( 'nonce', 'url' ) ) );