From c1ff69527826992337e56c28febedc185aad9ad7 Mon Sep 17 00:00:00 2001
From: Jan Herzan <jan.herzan@gmail.com>
Date: Fri, 21 Mar 2014 14:50:43 +0100
Subject: [PATCH 1/2] Some no-PHP generated buttons edited to be "primary".

---
 wp-admin/edit.php                | 2 +-
 wp-admin/includes/media.php      | 2 +-
 wp-admin/includes/meta-boxes.php | 6 +++---
 wp-admin/includes/template.php   | 2 +-
 wp-admin/upload.php              | 2 +-
 wp-admin/user-edit.php           | 4 ++--
 wp-admin/users.php               | 2 +-
 7 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/wp-admin/edit.php b/wp-admin/edit.php
index a062b09..32a9014 100644
--- a/wp-admin/edit.php
+++ b/wp-admin/edit.php
@@ -268,7 +268,7 @@ require_once( ABSPATH . 'wp-admin/admin-header.php' );
 <h2><?php
 echo esc_html( $post_type_object->labels->name );
 if ( current_user_can( $post_type_object->cap->create_posts ) )
-	echo ' <a href="' . esc_url( admin_url( $post_new_file ) ) . '" class="add-new-h2">' . esc_html( $post_type_object->labels->add_new ) . '</a>';
+	echo ' <a href="' . esc_url( admin_url( $post_new_file ) ) . '" class="button-primary">' . esc_html( $post_type_object->labels->add_new ) . '</a>';
 if ( ! empty( $_REQUEST['s'] ) )
 	printf( ' <span class="subtitle">' . __('Search results for &#8220;%s&#8221;') . '</span>', get_search_query() );
 ?></h2>
diff --git a/wp-admin/includes/media.php b/wp-admin/includes/media.php
index 678df79..9b2db4f 100644
--- a/wp-admin/includes/media.php
+++ b/wp-admin/includes/media.php
@@ -1817,7 +1817,7 @@ do_action( 'pre-plupload-upload-ui' ); ?>
 	<div class="drag-drop-inside">
 	<p class="drag-drop-info"><?php _e('Drop files here'); ?></p>
 	<p><?php _ex('or', 'Uploader: Drop files here - or - Select Files'); ?></p>
-	<p class="drag-drop-buttons"><input id="plupload-browse-button" type="button" value="<?php esc_attr_e('Select Files'); ?>" class="button" /></p>
+	<p class="drag-drop-buttons"><input id="plupload-browse-button" type="button" value="<?php esc_attr_e('Select Files'); ?>" class="button-primary" /></p>
 	</div>
 </div>
 <?php
diff --git a/wp-admin/includes/meta-boxes.php b/wp-admin/includes/meta-boxes.php
index 68d4611..31bc63f 100644
--- a/wp-admin/includes/meta-boxes.php
+++ b/wp-admin/includes/meta-boxes.php
@@ -105,7 +105,7 @@ switch ( $post->post_status ) {
 <option<?php selected( $post->post_status, 'draft' ); ?> value='draft'><?php _e('Draft') ?></option>
 <?php endif; ?>
 </select>
- <a href="#post_status" class="save-post-status hide-if-no-js button"><?php _e('OK'); ?></a>
+ <a href="#post_status" class="save-post-status hide-if-no-js button-primary"><?php _e('OK'); ?></a>
  <a href="#post_status" class="cancel-post-status hide-if-no-js button-cancel"><?php _e('Cancel'); ?></a>
 </div>
 
@@ -149,7 +149,7 @@ echo esc_html( $visibility_trans ); ?></span>
 <input type="radio" name="visibility" id="visibility-radio-private" value="private" <?php checked( $visibility, 'private' ); ?> /> <label for="visibility-radio-private" class="selectit"><?php _e('Private'); ?></label><br />
 
 <p>
- <a href="#visibility" class="save-post-visibility hide-if-no-js button"><?php _e('OK'); ?></a>
+ <a href="#visibility" class="save-post-visibility hide-if-no-js button-primary"><?php _e('OK'); ?></a>
  <a href="#visibility" class="cancel-post-visibility hide-if-no-js button-cancel"><?php _e('Cancel'); ?></a>
 </p>
 </div>
@@ -467,7 +467,7 @@ function post_categories_meta_box( $post, $box ) {
 						<?php echo $tax->labels->parent_item_colon; ?>
 					</label>
 					<?php wp_dropdown_categories( array( 'taxonomy' => $taxonomy, 'hide_empty' => 0, 'name' => 'new'.$taxonomy.'_parent', 'orderby' => 'name', 'hierarchical' => 1, 'show_option_none' => '&mdash; ' . $tax->labels->parent_item . ' &mdash;' ) ); ?>
-					<input type="button" id="<?php echo $taxonomy; ?>-add-submit" data-wp-lists="add:<?php echo $taxonomy ?>checklist:<?php echo $taxonomy ?>-add" class="button category-add-submit" value="<?php echo esc_attr( $tax->labels->add_new_item ); ?>" />
+					<input type="button" id="<?php echo $taxonomy; ?>-add-submit" data-wp-lists="add:<?php echo $taxonomy ?>checklist:<?php echo $taxonomy ?>-add" class="button-primary category-add-submit" value="<?php echo esc_attr( $tax->labels->add_new_item ); ?>" />
 					<?php wp_nonce_field( 'add-'.$taxonomy, '_ajax_nonce-add-'.$taxonomy, false ); ?>
 					<span id="<?php echo $taxonomy; ?>-ajax-response"></span>
 				</p>
diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php
index 80d6c9f..8a4d282 100644
--- a/wp-admin/includes/template.php
+++ b/wp-admin/includes/template.php
@@ -727,7 +727,7 @@ function touch_time( $edit = 1, $for_post = 1, $tab_index = 0, $multi = 0 ) {
 ?>
 
 <p>
-<a href="#edit_timestamp" class="save-timestamp hide-if-no-js button"><?php _e('OK'); ?></a>
+<a href="#edit_timestamp" class="save-timestamp hide-if-no-js button-primary"><?php _e('OK'); ?></a>
 <a href="#edit_timestamp" class="cancel-timestamp hide-if-no-js button-cancel"><?php _e('Cancel'); ?></a>
 </p>
 <?php
diff --git a/wp-admin/upload.php b/wp-admin/upload.php
index c38a0b6..249acf9 100644
--- a/wp-admin/upload.php
+++ b/wp-admin/upload.php
@@ -179,7 +179,7 @@ require_once( ABSPATH . 'wp-admin/admin-header.php' );
 <?php
 echo esc_html( $title );
 if ( current_user_can( 'upload_files' ) ) { ?>
-	<a href="media-new.php" class="add-new-h2"><?php echo esc_html_x('Add New', 'file'); ?></a><?php
+	<a href="media-new.php" class="button-primary"><?php echo esc_html_x('Add New', 'file'); ?></a><?php
 }
 if ( ! empty( $_REQUEST['s'] ) )
 	printf( '<span class="subtitle">' . __('Search results for &#8220;%s&#8221;') . '</span>', get_search_query() ); ?>
diff --git a/wp-admin/user-edit.php b/wp-admin/user-edit.php
index 7274f4d..e994865 100644
--- a/wp-admin/user-edit.php
+++ b/wp-admin/user-edit.php
@@ -215,9 +215,9 @@ include (ABSPATH . 'wp-admin/admin-header.php');
 echo esc_html( $title );
 if ( ! IS_PROFILE_PAGE ) {
 	if ( current_user_can( 'create_users' ) ) { ?>
-		<a href="user-new.php" class="add-new-h2"><?php echo esc_html_x( 'Add New', 'user' ); ?></a>
+		<a href="user-new.php" class="button-primary"><?php echo esc_html_x( 'Add New', 'user' ); ?></a>
 	<?php } elseif ( is_multisite() && current_user_can( 'promote_users' ) ) { ?>
-		<a href="user-new.php" class="add-new-h2"><?php echo esc_html_x( 'Add Existing', 'user' ); ?></a>
+		<a href="user-new.php" class="button-primary"><?php echo esc_html_x( 'Add Existing', 'user' ); ?></a>
 	<?php }
 } ?>
 </h2>
diff --git a/wp-admin/users.php b/wp-admin/users.php
index 1dfd73c..92db16d 100644
--- a/wp-admin/users.php
+++ b/wp-admin/users.php
@@ -427,7 +427,7 @@ if ( ! empty($messages) ) {
 <?php
 echo esc_html( $title );
 if ( current_user_can( 'create_users' ) ) { ?>
-	<a href="user-new.php" class="add-new-h2"><?php echo esc_html_x( 'Add New', 'user' ); ?></a>
+	<a href="user-new.php" class="button-primary"><?php echo esc_html_x( 'Add New', 'user' ); ?></a>
 <?php } elseif ( is_multisite() && current_user_can( 'promote_users' ) ) { ?>
 	<a href="user-new.php" class="add-new-h2"><?php echo esc_html_x( 'Add Existing', 'user' ); ?></a>
 <?php }
-- 
1.8.0.msysgit.0


From c955db7040d5e0a91f55f7356e2eadcb9a0f3780 Mon Sep 17 00:00:00 2001
From: Jan Herzan <jan.herzan@gmail.com>
Date: Fri, 21 Mar 2014 14:51:08 +0100
Subject: [PATCH 2/2] Some PHP generated submit buttons edited to be
 "primary".

---
 wp-admin/includes/media.php    | 2 +-
 wp-admin/includes/template.php | 2 +-
 wp-admin/users.php             | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/wp-admin/includes/media.php b/wp-admin/includes/media.php
index 9b2db4f..c768e7c 100644
--- a/wp-admin/includes/media.php
+++ b/wp-admin/includes/media.php
@@ -1842,7 +1842,7 @@ do_action( 'post-plupload-upload-ui' ); ?>
 	<p id="async-upload-wrap">
 		<label class="screen-reader-text" for="async-upload"><?php _e('Upload'); ?></label>
 		<input type="file" name="async-upload" id="async-upload" />
-		<?php submit_button( __( 'Upload' ), 'button', 'html-upload', false ); ?>
+		<?php submit_button( __( 'Upload' ), 'button-primary', 'html-upload', false ); ?>
 		<a href="#" onclick="try{top.tb_remove();}catch(e){}; return false;"><?php _e('Cancel'); ?></a>
 	</p>
 	<div class="clear"></div>
diff --git a/wp-admin/includes/template.php b/wp-admin/includes/template.php
index 8a4d282..0e2346e 100644
--- a/wp-admin/includes/template.php
+++ b/wp-admin/includes/template.php
@@ -838,7 +838,7 @@ function wp_import_upload_form( $action ) {
 <input type="hidden" name="action" value="save" />
 <input type="hidden" name="max_file_size" value="<?php echo $bytes; ?>" />
 </p>
-<?php submit_button( __('Upload file and import'), 'button' ); ?>
+<?php submit_button( __('Upload file and import') ); ?>
 </form>
 <?php
 	endif;
diff --git a/wp-admin/users.php b/wp-admin/users.php
index 92db16d..b529c95 100644
--- a/wp-admin/users.php
+++ b/wp-admin/users.php
@@ -249,7 +249,7 @@ case 'delete':
 		wp_dropdown_users( array( 'name' => 'reassign_user', 'exclude' => array_diff( $userids, array($current_user->ID) ) ) ); ?></li>
 	</ul></fieldset>
 	<input type="hidden" name="action" value="dodelete" />
-	<?php submit_button( __('Confirm Deletion'), 'secondary' ); ?>
+	<?php submit_button( __('Confirm Deletion') ); ?>
 <?php else : ?>
 	<p><?php _e('There are no valid users selected for deletion.'); ?></p>
 <?php endif; ?>
-- 
1.8.0.msysgit.0

