From 1faa9ffc1c90f0c1f6d8adfd79f7adb50e4057ef Mon Sep 17 00:00:00 2001 From: Matt Mullenweg Date: Mon, 5 Sep 2005 23:33:10 +0000 Subject: [PATCH] Fix menu annoyance. Clean up themes.php code. git-svn-id: https://develop.svn.wordpress.org/trunk@2839 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/admin-functions.php | 18 ++++++- wp-admin/menu-header.php | 2 +- wp-admin/themes.php | 102 +++++++++++------------------------ wp-admin/wp-admin.css | 30 +++++++---- 4 files changed, 69 insertions(+), 83 deletions(-) diff --git a/wp-admin/admin-functions.php b/wp-admin/admin-functions.php index 830d114d75..b7cc69cafc 100644 --- a/wp-admin/admin-functions.php +++ b/wp-admin/admin-functions.php @@ -1399,4 +1399,20 @@ function get_importers() { return $wp_importers; } -?> +function current_theme_info() { + $themes = get_themes(); + $current_theme = get_current_theme(); + $ct->title = $themes[$current_theme]['Title']; + $ct->version = $themes[$current_theme]['Version']; + $ct->parent_theme = $themes[$current_theme]['Parent Theme']; + $ct->template_dir = $themes[$current_theme]['Template Dir']; + $ct->stylesheet_dir = $themes[$current_theme]['Stylesheet Dir']; + $ct->template = $themes[$current_theme]['Template']; + $ct->stylesheet = $themes[$current_theme]['Stylesheet']; + $ct->screenshot = $themes[$current_theme]['Screenshot']; + $ct->description = $themes[$current_theme]['Description']; + $ct->author = $themes[$current_theme]['Author']; + return $ct; +} + +?> \ No newline at end of file diff --git a/wp-admin/menu-header.php b/wp-admin/menu-header.php index db4ac133a5..379ee4ca27 100644 --- a/wp-admin/menu-header.php +++ b/wp-admin/menu-header.php @@ -26,7 +26,7 @@ foreach ($menu as $item) { // Sub-menu if ( isset($submenu["$parent_file"]) ) : ?> -