From 0d1995a828dd530092d23ef8a1c5062e080facec Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sat, 9 Aug 2008 12:41:23 +0000 Subject: - Patch #268063 by boombatower, chx, cwgordon7, Damien Tournoud: move includes/tests to simpletest/tests and provide hidden .info propery --- modules/system/system.admin.inc | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'modules/system/system.admin.inc') diff --git a/modules/system/system.admin.inc b/modules/system/system.admin.inc index a28f96074..7c1bf0519 100644 --- a/modules/system/system.admin.inc +++ b/modules/system/system.admin.inc @@ -614,6 +614,13 @@ function system_modules($form_state = array()) { // Get current list of modules. $files = module_rebuild_cache(); + // Remove hidden modules from display list. + foreach ($files as $filename => $file) { + if (!empty($file->info['hidden'])) { + unset($files[$filename]); + } + } + uasort($files, 'system_sort_modules_by_info_name'); if (!empty($form_state['storage'])) { @@ -705,7 +712,7 @@ function system_sort_modules_by_info_name($a, $b) { return strcasecmp($a->info['name'], $b->info['name']); } -/** +/** * Build a table row for the system modules page. */ function _system_modules_build_row($info, $extra) { @@ -881,7 +888,7 @@ function system_modules_submit($form, &$form_state) { ); } else { - $dependencies[$name]['dependencies'][$dependency] = $files[$dependency]->info['name']; + $dependencies[$name]['dependencies'][$dependency] = $files[$dependency]->info['name']; } $modules[$dependency] = array('group' => $files[$dependency]->info['package'], 'enabled' => TRUE); } @@ -2092,10 +2099,10 @@ function theme_system_modules_fieldset($form) { // Add the description, along with any dependencies. $description .= drupal_render($module['description']); if ($module['#dependencies']) { - $description .= '
' . t('Depends on: ') . implode(', ', $module['#dependencies']) . '
'; + $description .= '
' . t('Depends on: ') . implode(', ', $module['#dependencies']) . '
'; } if ($module['#dependents']) { - $description .= '
' . t('Required by: ') . implode(', ', $module['#dependents']) . '
'; + $description .= '
' . t('Required by: ') . implode(', ', $module['#dependents']) . '
'; } $row[] = array('data' => $description, 'class' => 'description'); $rows[] = $row; -- cgit v1.2.3