summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--modules/block/block.module18
1 files changed, 10 insertions, 8 deletions
diff --git a/modules/block/block.module b/modules/block/block.module
index 1f7079d38..0f2fb1e4e 100644
--- a/modules/block/block.module
+++ b/modules/block/block.module
@@ -88,16 +88,18 @@ function block_menu($may_cache) {
'callback' => 'drupal_get_form',
'callback arguments' => array('block_box_form'),
'type' => MENU_LOCAL_TASK);
+ $default = variable_get('theme_default', 'bluemarine');
foreach (list_themes() as $key => $theme) {
if ($theme->status) {
- if ($key == variable_get('theme_default', 'bluemarine')) {
- $items[] = array('path' => 'admin/build/block/list/'. $key, 'title' => t('!key settings', array('!key' => $key)),
- 'access' => user_access('administer blocks'), 'type' => MENU_DEFAULT_LOCAL_TASK, 'weight' => -10);
- }
- else {
- $items[] = array('path' => 'admin/build/block/list/'. $key, 'title' => t('!key settings', array('!key' => $key)),
- 'access' => user_access('administer blocks'), 'type' => MENU_LOCAL_TASK);
- }
+ $items[] = array(
+ 'path' => 'admin/build/block/list/'. $key,
+ 'title' => t('!key settings', array('!key' => $key)),
+ 'callback' => 'drupal_get_form',
+ 'callback arguments' => array('block_admin_display', $key),
+ 'access' => user_access('administer blocks'),
+ 'type' => $key== $default ? MENU_DEFAULT_LOCAL_TASK : MENU_LOCAL_TASK,
+ 'weight' => $key == $default ? -10 : 0,
+ );
}
}
}