Changeset 36837 for trunk/src/wp-includes/class-wp-customize-manager.php
- Timestamp:
- 03/03/2016 07:55:15 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-customize-manager.php
r36796 r36837 1849 1849 $this->register_control_type( 'WP_Customize_Cropped_Image_Control' ); 1850 1850 $this->register_control_type( 'WP_Customize_Site_Icon_Control' ); 1851 $this->register_control_type( 'WP_Customize_ Site_Logo_Control' );1851 $this->register_control_type( 'WP_Customize_Custom_Logo_Control' ); 1852 1852 $this->register_control_type( 'WP_Customize_Theme_Control' ); 1853 1853 … … 1961 1961 ) ) ); 1962 1962 1963 $this->add_setting( ' site_logo', array(1964 'theme_supports' => array( ' site-logo' ),1963 $this->add_setting( 'custom_logo', array( 1964 'theme_supports' => array( 'custom-logo' ), 1965 1965 'transport' => 'postMessage', 1966 1966 ) ); 1967 1967 1968 $this->add_control( new WP_Customize_ Site_Logo_Control( $this, 'site_logo', array(1968 $this->add_control( new WP_Customize_Custom_Logo_Control( $this, 'custom_logo', array( 1969 1969 'label' => __( 'Logo' ), 1970 1970 'section' => 'title_tagline', … … 1973 1973 1974 1974 if ( isset( $this->selective_refresh ) ) { 1975 $this->selective_refresh->add_partial( ' site_logo', array(1976 'settings' => array( ' site_logo' ),1977 'selector' => '. site-logo-link',1978 'render_callback' => array( $this, '_render_ site_logo_partial' ),1975 $this->selective_refresh->add_partial( 'custom_logo', array( 1976 'settings' => array( 'custom_logo' ), 1977 'selector' => '.custom-logo-link', 1978 'render_callback' => array( $this, '_render_custom_logo_partial' ), 1979 1979 'container_inclusive' => true, 1980 1980 ) ); … … 2212 2212 2213 2213 /** 2214 * Callback for rendering the site logo, used in the site_logo partial.2214 * Callback for rendering the custom logo, used in the custom_logo partial. 2215 2215 * 2216 2216 * This method exists because the partial object and context data are passed 2217 * into a partial's render_callback so we cannot use get_ the_site_logo() as2217 * into a partial's render_callback so we cannot use get_custom_logo() as 2218 2218 * the render_callback directly since it expects a blog ID as the first 2219 2219 * argument. When WP no longer supports PHP 5.3, this method can be removed … … 2225 2225 * @access private 2226 2226 * 2227 * @return string Sitelogo.2228 */ 2229 public function _render_ site_logo_partial() {2230 return get_ the_site_logo();2227 * @return string Custom logo. 2228 */ 2229 public function _render_custom_logo_partial() { 2230 return get_custom_logo(); 2231 2231 } 2232 2232 }
Note: See TracChangeset
for help on using the changeset viewer.