Screen icons

git-svn-id: http://svn.automattic.com/wordpress/trunk@9903 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
azaozz 2008-11-26 13:51:25 +00:00
parent ba7c715d8e
commit 7c68e6945a
53 changed files with 140 additions and 12 deletions

View File

@ -112,7 +112,7 @@ if ( function_exists('mb_strlen') ) {
do_action('admin_notices');
screen_meta($hook_suffix);
unset($hook_suffix);
//unset($hook_suffix);
if ( $parent_file == 'options-general.php' ) {
require(ABSPATH . 'wp-admin/options-head.php');

View File

@ -130,6 +130,7 @@ $messages[5] = __('Category not updated.');
?>
<div class="wrap nosubsub">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php

View File

@ -1520,3 +1520,52 @@ form p.submit a.cancel:hover {
background-color: transparent;
text-shadow: rgba(255,255,255,0.7) 0 1px 0;
}
#icon-edit,
#icon-post {
background: transparent url(../images/icons32.png) no-repeat -552px -5px;
}
#icon-index {
background: transparent url(../images/icons32.png) no-repeat -137px -5px;
}
#icon-upload {
background: transparent url(../images/icons32.png) no-repeat -251px -5px;
}
#icon-link-manager,
#icon-link {
background: transparent url(../images/icons32.png) no-repeat -190px -5px;
}
#icon-edit-pages,
#icon-page {
background: transparent url(../images/icons32.png) no-repeat -312px -5px;
}
#icon-edit-comments {
background: transparent url(../images/icons32.png) no-repeat -72px -5px;
}
#icon-themes {
background: transparent url(../images/icons32.png) no-repeat -11px -5px;
}
#icon-plugins {
background: transparent url(../images/icons32.png) no-repeat -370px -5px;
}
#icon-users
#icon-user-edit {
background: transparent url(../images/icons32.png) no-repeat -600px -5px;
}
#icon-import,
#icon-admin {
background: transparent url(../images/icons32.png) no-repeat -432px -5px;
}
#icon-options-general {
background: transparent url(../images/icons32.png) no-repeat -492px -5px;
}

View File

@ -85,6 +85,7 @@ $search_dirty = ( isset($_GET['s']) ) ? $_GET['s'] : '';
$search = attribute_escape( $search_dirty ); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php

View File

@ -507,6 +507,7 @@ require_once('admin-header.php');
<?php endif; ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php if ( $notice ) : ?>
<div id="notice" class="error"><p><?php echo $notice ?></p></div>

View File

@ -60,6 +60,7 @@ $messages[5] = __('Category not updated.');
$messages[6] = __('Categories deleted.'); ?>
<div class="wrap nosubsub">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php if ( isset($_GET['message']) && ( $msg = (int) $_GET['message'] ) ) : ?>

View File

@ -341,6 +341,7 @@ require_once ('admin-header.php');
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php if ( isset( $_GET['added'] ) ) : ?>

View File

@ -391,6 +391,7 @@ require_once('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form name="post" action="page.php" method="post" id="post">

View File

@ -99,6 +99,7 @@ if ( is_singular() ) {
require_once('admin-header.php'); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php if ( isset($_GET['locked']) || isset($_GET['skipped']) || isset($_GET['updated']) ) { ?>

View File

@ -129,6 +129,7 @@ $messages[5] = __('Tag not updated.');
$messages[6] = __('Tags deleted.'); ?>
<div class="wrap nosubsub">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php if ( isset($_GET['message']) && ( $msg = (int) $_GET['message'] ) ) : ?>

View File

@ -91,6 +91,7 @@ else
$mode = attribute_escape($_GET['mode']); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php

View File

@ -23,6 +23,7 @@ require_once ('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<p><?php _e('When you click the button below WordPress will create an XML file for you to save to your computer.'); ?></p>

BIN
wp-admin/images/icons32.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

View File

@ -13,6 +13,7 @@ require_once ('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<p><?php _e('If you have posts or comments in another system, WordPress can import those into this blog. To get started, choose a system to import from below:'); ?></p>

View File

@ -54,7 +54,10 @@ class Blogger_Import {
$auth = __('Authorize');
echo "
<div class='wrap'><h2>$title</h2><p>$welcome</p><p>$prereqs</p><p>$stepone</p>
<div class='wrap'>
".screen_icon()."
<h2>$title</h2>
<p>$welcome</p><p>$prereqs</p><p>$stepone</p>
<form action='$auth_url' method='get'>
<p class='submit' style='text-align:left;'>
<input type='submit' class='button' value='$auth' />
@ -68,7 +71,9 @@ class Blogger_Import {
}
function uh_oh($title, $message, $info) {
echo "<div class='wrap'><h2>$title</h2><p>$message</p><pre>$info</pre></div>";
echo "<div class='wrap'>";
screen_icon();
echo "<h2>$title</h2><p>$message</p><pre>$info</pre></div>";
}
function auth() {

View File

@ -21,6 +21,7 @@ class BW_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import Blogware').'</h2>';
}

View File

@ -18,6 +18,7 @@ class BunnyTags_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import Bunny&#8217;s Technorati Tags').'</h2>';
echo '<p>'.__('Steps may take a few minutes depending on the size of your database. Please be patient.').'<br /><br /></p>';
}

View File

@ -198,6 +198,7 @@ class Dotclear_Import {
function header()
{
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import DotClear').'</h2>';
echo '<p>'.__('Steps may take a few minutes depending on the size of your database. Please be patient.').'</p>';
}

View File

@ -20,6 +20,7 @@ class GM_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import GreyMatter').'</h2>';
}

View File

@ -17,6 +17,7 @@ class JeromesKeyword_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import Jerome&#8217;s Keywords').'</h2>';
echo '<p>'.__('Steps may take a few minutes depending on the size of your database. Please be patient.').'<br /><br /></p>';
}

View File

@ -19,6 +19,7 @@ class LJ_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import LiveJournal').'</h2>';
}

View File

@ -24,6 +24,7 @@ class MT_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import Movable Type or TypePad').'</h2>';
}
@ -191,6 +192,7 @@ class MT_Import {
function mt_authors_form() {
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php _e('Assign Authors'); ?></h2>
<p><?php _e('To make it easier for you to edit and save the imported posts and drafts, you may want to change the name of the author of the posts. For example, you may want to import all the entries as admin\'s entries.'); ?></p>
<p><?php _e('Below, you can see the names of the authors of the MovableType posts in <em>italics</em>. For each of these names, you can either pick an author in your WordPress installation from the menu, or enter a name for the author in the textbox.'); ?></p>

View File

@ -22,6 +22,7 @@ class RSS_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import RSS').'</h2>';
}

View File

@ -16,6 +16,7 @@
class STP_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import Simple Tagging').'</h2>';
echo '<p>'.__('Steps may take a few minutes depending on the size of your database. Please be patient.').'<br /><br /></p>';
}

View File

@ -52,6 +52,7 @@ class Textpattern_Import {
function header()
{
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import Textpattern').'</h2>';
echo '<p>'.__('Steps may take a few minutes depending on the size of your database. Please be patient.').'</p>';
}

View File

@ -17,6 +17,7 @@ class UTW_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import Ultimate Tag Warrior').'</h2>';
echo '<p>'.__('Steps may take a few minutes depending on the size of your database. Please be patient.').'<br /><br /></p>';
}

View File

@ -34,6 +34,7 @@ class WP_Import {
function header() {
echo '<div class="wrap">';
screen_icon();
echo '<h2>'.__('Import WordPress').'</h2>';
}
@ -197,6 +198,7 @@ class WP_Import {
function wp_authors_form() {
?>
<?php screen_icon(); ?>
<h2><?php _e('Assign Authors'); ?></h2>
<p><?php _e('To make it easier for you to edit and save the imported posts and drafts, you may want to change the name of the author of the posts. For example, you may want to import all the entries as <code>admin</code>s entries.'); ?></p>
<?php
@ -220,6 +222,7 @@ class WP_Import {
if ( $this->allow_fetch_attachments() ) {
?>
</ol>
<?php screen_icon(); ?>
<h2><?php _e('Import Attachments'); ?></h2>
<p>
<input type="checkbox" value="1" name="attachments" id="import-attachments" />

View File

@ -64,6 +64,7 @@ class WP_Categories_to_Tags {
echo '<br class="clear" />';
if ( $cat_num > 0 ) {
screen_icon();
echo '<h2>' . sprintf( __ngettext( 'Convert Category to Tag.', 'Convert Categories (%d) to Tags.', $cat_num ), $cat_num ) . '</h2>';
echo '<div class="narrow">';
echo '<p>' . __('Hey there. Here you can selectively convert existing categories to tags. To get started, check the categories you wish to be converted, then click the Convert button.') . '</p>';
@ -139,6 +140,7 @@ function check_all_rows() {
echo '<br class="clear" />';
if ( $tags_num > 0 ) {
screen_icon();
echo '<h2>' . sprintf( __ngettext( 'Convert Tag to Category.', 'Convert Tags (%d) to Categories.', $tags_num ), $tags_num ) . '</h2>';
echo '<div class="narrow">';
echo '<p>' . __('Here you can selectively converts existing tags to categories. To get started, check the tags you wish to be converted, then click the Convert button.') . '</p>';

View File

@ -3327,4 +3327,18 @@ function add_contextual_help($screen, $help) {
$_wp_contextual_help[$screen] = $help;
}
function screen_icon() {
global $parent_file, $hook_suffix;
if ( isset($parent_file) && !empty($parent_file) )
$name = substr($parent_file, 0, -4);
else
$name = str_replace(array('.php', '-new', '-add'), '', $hook_suffix);
unset($hook_suffix);
?>
<div id="icon-<?php echo $name; ?>" class="icon32"><br /></div>
<?php
}
?>

View File

@ -29,6 +29,7 @@ $today = current_time('mysql', 1);
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<div id="dashboard-widgets-wrap">

View File

@ -70,6 +70,7 @@ switch ($order_by) {
} ?>
<div class="wrap nosubsub">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php

View File

@ -56,6 +56,7 @@ if ( isset($_GET['inline']) ) {
$parent_file = 'edit.php';
require_once('admin-header.php'); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form enctype="multipart/form-data" method="post" action="media-upload.php?inline=&amp;upload-page-form=" class="media-upload-form type-form validate" id="file-form">

View File

@ -16,6 +16,7 @@ include('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">

View File

@ -49,6 +49,7 @@ include('./admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">

View File

@ -17,6 +17,7 @@ include('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form action="options.php" method="post">

View File

@ -17,6 +17,7 @@ include('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">

View File

@ -123,6 +123,7 @@ else
<?php endif; ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form name="form" action="options-permalink.php" method="post">

View File

@ -16,6 +16,7 @@ include('./admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">

View File

@ -16,6 +16,7 @@ include('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form name="form1" method="post" action="options.php">

View File

@ -16,6 +16,7 @@ include('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form method="post" action="options.php">

View File

@ -96,7 +96,8 @@ default:
</div>
<?php endif; ?>
<div class="wrap">
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<div class="tablenav">
<div class="alignleft">

View File

@ -52,6 +52,7 @@ do_action('install_plugins_pre_' . $tab); //Used to override the general interfa
include('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<ul class="subsubsub">

View File

@ -201,6 +201,7 @@ if ( !empty($invalid) )
<?php endif; ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<p><?php _e('Plugins extend and expand the functionality of WordPress. Once a plugin is installed, you may activate it or deactivate it here.'); ?></p>

View File

@ -99,6 +99,7 @@ $description = get_file_description($file);
$desc_header = ( $description != $file_show ) ? "$description</strong> (%s)" : "%s";
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<div class="bordertitle">
<form id="themeselector" action="theme-editor.php" method="post">

View File

@ -100,6 +100,7 @@ function theme_update_available( $theme ) {
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<h3><?php _e('Current Theme'); ?></h3>

View File

@ -17,6 +17,7 @@ require_once('admin-header.php');
if ( ! $is_opera ) {
?>
<div id="gears-info-box" class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<img src="images/gear.png" title="Gear" alt="" class="gears-img" />

View File

@ -88,10 +88,11 @@ function dismissed_updates() {
*/
function core_upgrade_preamble() {
$updates = get_core_updates();
echo '<div class="wrap">';
echo '<h2>' . __('Upgrade WordPress') . '</h2>';
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php _e('Upgrade WordPress'); ?></h2>
<?php
if ( !isset($updates[0]->response) || 'latest' == $updates[0]->response ) {
echo '<h3>';
_e('You have the latest version of WordPress. You do not need to upgrade');
@ -146,9 +147,11 @@ function do_core_upgrade() {
request_filesystem_credentials($url, '', true); //Failed to connect, Error and request again
return;
}
echo '<div class="wrap">';
echo '<h2>' . __('Upgrade WordPress') . '</h2>';
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php _e('Upgrade WordPress'); ?></h2>
<?php
if ( $wp_filesystem->errors->get_error_code() ) {
foreach ( $wp_filesystem->errors->get_error_messages() as $message )
show_message($message);

View File

@ -163,6 +163,7 @@ if ( isset($_GET['message']) && (int) $_GET['message'] ) {
<?php do_action('restrict_manage_posts'); ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php

View File

@ -176,7 +176,8 @@ include ('admin-header.php');
<?php endif; ?>
<div class="wrap" id="profile-page">
<h2><?php echo wp_specialchars( $title ); ?></h2>
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form id="your-profile" action="" method="post">
<?php wp_nonce_field('update-user_' . $user_id) ?>

View File

@ -42,6 +42,7 @@ require_once ('admin-header.php');
?>
<div class="wrap">
<?php screen_icon(); ?>
<h2 id="add-new-user"><?php _e('Add New User') ?></h2>
<?php if ( isset($errors) && is_wp_error( $errors ) ) : ?>

View File

@ -237,6 +237,7 @@ if ( ! empty($messages) ) {
} ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<div class="filter">

View File

@ -233,6 +233,7 @@ require_once( 'admin-header.php' ); ?>
<?php endif; ?>
<div class="wrap">
<?php screen_icon(); ?>
<h2><?php echo wp_specialchars( $title ); ?></h2>
<form id="widgets-filter" action="" method="get">

View File

@ -1214,6 +1214,7 @@ strong .post-com-count {
margin-top: 0.5em;
width: 100%;
margin-bottom: -8px;
clear: both;
}
.form-table td,
@ -3111,3 +3112,9 @@ table.fixed {
text-shadow: rgba(255,255,255,0.8) 0 1px 0;
}
.icon32 {
float: left;
height: 36px;
margin: 8px 6px 0 0;
width: 36px;
}