Theme Customizer: Link the current theme screenshot to the customizer. see #19910.

git-svn-id: https://develop.svn.wordpress.org/trunk@20747 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Daryl Koopersmith 2012-05-09 01:38:54 +00:00
parent d454d3a0f3
commit 548960fe58
1 changed files with 7 additions and 3 deletions

View File

@ -115,10 +115,14 @@ $ct = wp_get_theme();
$screenshot = $ct->get_screenshot();
$class = $screenshot ? 'has-screenshot' : '';
$customize_title = sprintf( __( 'Customize “%s”' ), $ct->display('Name') );
?>
<div id="current-theme" class="<?php echo esc_attr( $class ); ?>">
<?php if ( $screenshot ) : ?>
<a href="<?php echo wp_customize_url( $ct->get_stylesheet() ); ?>" class="load-customize hide-if-no-customize" title="<?php echo esc_attr( $customize_title ); ?>">
<img src="<?php echo esc_url( $screenshot ); ?>" alt="<?php esc_attr_e( 'Current theme preview' ); ?>" />
</a>
<?php endif; ?>
<h3><?php _e('Current Theme'); ?></h3>
@ -136,7 +140,7 @@ $class = $screenshot ? 'has-screenshot' : '';
</div>
<div class="theme-options">
<a href="<?php echo wp_customize_url( $ct->get_stylesheet() ); ?>" class="load-customize hide-if-no-customize" title="<?php echo esc_attr( sprintf( __( 'Customize &#8220;%s&#8221;' ), $ct->display('Name') ) ); ?>"><?php _e( 'Customize' )?></a>
<a href="<?php echo wp_customize_url( $ct->get_stylesheet() ); ?>" class="load-customize hide-if-no-customize" title="<?php echo esc_attr( $customize_title ); ?>"><?php _e( 'Customize' )?></a>
<span><?php _e( 'Options:' )?></span>
<?php
// Pretend you didn't see this.