Make WordPress Core

Ticket #19020: 19020-zeo-2011-theme-options.php.diff

File 19020-zeo-2011-theme-options.php.diff, 2.9 KB (added by Zeo, 14 years ago)

Patch refresh. s/Layout/Default Layout. Also some whitespace clean up.

  • wp-content/themes/twentyeleven/inc/theme-options.php

     
    4848        );
    4949
    5050        // Register our settings field group
    51         add_settings_section( 
     51        add_settings_section(
    5252                'general', // Unique identifier for the settings section
    5353                '', // Section title (we don't want one)
    54                 '__return_false', // Section callback (we don't want anything) 
     54                '__return_false', // Section callback (we don't want anything)
    5555                'theme_options' // Menu slug, used to uniquely identify the page; see twentyeleven_theme_options_add_page()
    5656        );
    5757
    5858        // Register our individual settings fields
    59         add_settings_field( 
     59        add_settings_field(
    6060                'color_scheme',  // Unique identifier for the field for this section
    6161                __( 'Color Scheme', 'twentyeleven' ), // Setting field label
    6262                'twentyeleven_settings_field_color_scheme', // Function that renders the settings field
     
    6565        );
    6666
    6767        add_settings_field( 'link_color', __( 'Link Color', 'twentyeleven' ), 'twentyeleven_settings_field_link_color', 'theme_options', 'general' );
    68         add_settings_field( 'layout',     __( 'Layout',     'twentyeleven' ), 'twentyeleven_settings_field_layout',     'theme_options', 'general' );
     68        add_settings_field( 'layout',     __( 'Default Layout',     'twentyeleven' ), 'twentyeleven_settings_field_layout',     'theme_options', 'general' );
    6969}
    7070add_action( 'admin_init', 'twentyeleven_theme_options_init' );
    7171
     
    118118        get_current_screen()->add_help_tab( array(
    119119                'title' => __( 'Overview', 'twentyeleven' ),
    120120                'id' => 'theme-options-help',
    121                 'content' => 
     121                'content' =>
    122122                        '<p>' . __( 'Some themes provide customization options that are grouped together on a Theme Options screen. If you change themes, options may change or disappear, as they are theme-specific. Your current theme, Twenty Eleven, provides the following Theme Options:', 'twentyeleven' ) . '</p>' .
    123123                        '<ol>' .
    124124                                '<li>' . __( '<strong>Color Scheme</strong>: You can choose a color palette of "Light" (light background with dark text) or "Dark" (dark background with light text) for your site.', 'twentyeleven' ) . '</li>' .
     
    237237
    238238/**
    239239 * Renders the Color Scheme setting field.
    240  * 
     240 *
    241241 * @since Twenty Eleven 1.3
    242242 */
    243243function twentyeleven_settings_field_color_scheme() {
     
    261261
    262262/**
    263263 * Renders the Link Color setting field.
    264  * 
     264 *
    265265 * @since Twenty Eleven 1.3
    266266 */
    267267function twentyeleven_settings_field_link_color() {
     
    278278
    279279/**
    280280 * Renders the Layout setting field.
    281  * 
     281 *
    282282 * @since Twenty Eleven 1.3
    283283 */
    284284function twentyeleven_settings_field_layout() {
     
    439439
    440440        return array_merge( $existing_classes, $classes );
    441441}
    442 add_filter( 'body_class', 'twentyeleven_layout_classes' );
    443  No newline at end of file
     442add_filter( 'body_class', 'twentyeleven_layout_classes' );