- Patch #134161 by chx: no menu tabs for themes.
parent
ec3c0716aa
commit
b0676cf351
|
@ -199,13 +199,13 @@ function _theme_build_registry($theme, $theme_engine) {
|
|||
* An array of the currently available themes.
|
||||
*/
|
||||
function list_themes($refresh = FALSE) {
|
||||
static $list;
|
||||
static $list = array();
|
||||
|
||||
if ($refresh) {
|
||||
unset($list);
|
||||
$list = array();
|
||||
}
|
||||
|
||||
if (!$list) {
|
||||
if (empty($list)) {
|
||||
$list = array();
|
||||
$result = db_query("SELECT * FROM {system} WHERE type = 'theme'");
|
||||
while ($theme = db_fetch_object($result)) {
|
||||
|
|
|
@ -1258,6 +1258,7 @@ function system_themes_form_submit($form_id, $form_values) {
|
|||
db_query("UPDATE {system} SET status = 1 WHERE type = 'theme' AND name = 'garland'");
|
||||
}
|
||||
|
||||
list_themes(TRUE);
|
||||
menu_rebuild();
|
||||
drupal_set_message(t('The configuration options have been saved.'));
|
||||
return 'admin/build/themes';
|
||||
|
|
Loading…
Reference in New Issue