Changeset 20119
- Timestamp:
- 03/06/2012 01:59:50 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/class-wp-theme.php
r20112 r20119 28 28 'TextDomain' => 'Text Domain', 29 29 'DomainPath' => 'Domain Path', 30 ); 31 32 /** 33 * Default themes. 34 * 35 * @static 36 * @access private 37 * @var array 38 */ 39 private static $default_themes = array( 40 'classic' => 'WordPress Classic', 41 'default' => 'WordPress Default', 42 'twentyten' => 'Twenty Ten', 43 'twentyeleven' => 'Twenty Eleven', 30 44 ); 31 45 … … 177 191 } else { 178 192 $this->headers = get_file_data( $this->theme_root . '/' . $theme_file, self::$file_headers, 'theme' ); 193 // Default themes always trump their pretenders. 194 // Properly identify default themes that are inside a directory within wp-content/themes. 195 if ( $default_theme_slug = array_search( $this->headers['Name'], self::$default_themes ) ) { 196 if ( basename( $this->stylesheet ) != $default_theme_slug ) 197 $this->headers['Name'] .= '/' . $this->stylesheet; 198 } 179 199 } 180 200 … … 208 228 } 209 229 } 210 211 // @TODO Check for theme name collision. But guess what? We don't care anymore! We only care about clashing matches found in search_theme_directories().212 230 213 231 // Set the parent, if we're a child theme.
Note: See TracChangeset
for help on using the changeset viewer.