From 61ffa682c151845cc9d43600d93fe263b8374f47 Mon Sep 17 00:00:00 2001 From: Ryan Boren Date: Thu, 25 Feb 2010 22:04:59 +0000 Subject: [PATCH] Note theme support for custom background, header, and menus. see #11817 git-svn-id: https://develop.svn.wordpress.org/trunk@13417 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-content/themes/twentyten/functions.php | 3 +++ wp-includes/theme.php | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/wp-content/themes/twentyten/functions.php b/wp-content/themes/twentyten/functions.php index f6669312c4..d0257cffa5 100644 --- a/wp-content/themes/twentyten/functions.php +++ b/wp-content/themes/twentyten/functions.php @@ -31,6 +31,9 @@ function twentyten_init() { // This theme needs post thumbnails add_theme_support( 'post-thumbnails' ); + // This theme uses wp_nav_menu() + add_theme_support( 'nav-menus' ); + // We'll be using them for custom header images on posts and pages // so we want them to be 940 pixels wide by 198 pixels tall (larger images will be auto-cropped to fit) set_post_thumbnail_size( HEADER_IMAGE_WIDTH, HEADER_IMAGE_HEIGHT, true ); diff --git a/wp-includes/theme.php b/wp-includes/theme.php index 2ac97c4430..8b29dff66c 100644 --- a/wp-includes/theme.php +++ b/wp-includes/theme.php @@ -1327,6 +1327,8 @@ function add_custom_image_header($header_callback, $admin_header_callback, $admi if ( ! empty($header_callback) ) add_action('wp_head', $header_callback); + add_theme_support( 'custom-header' ); + if ( ! is_admin() ) return; require_once(ABSPATH . 'wp-admin/custom-header.php'); @@ -1393,6 +1395,8 @@ function add_custom_background($header_callback = '', $admin_header_callback = ' add_action('wp_head', $header_callback); + add_theme_support( 'custom-background' ); + if ( ! is_admin() ) return; require_once(ABSPATH . 'wp-admin/custom-background.php');