summaryrefslogtreecommitdiff
path: root/themes
diff options
context:
space:
mode:
authorAngie Byron <webchick@24967.no-reply.drupal.org>2010-11-20 04:03:51 +0000
committerAngie Byron <webchick@24967.no-reply.drupal.org>2010-11-20 04:03:51 +0000
commit1a91990cae84f045b774e0eb308334dea1e97b28 (patch)
tree8ce6d346117837a69d06850c132013eab6b3295d /themes
parentaa10522336e69d462176e7505f3cdc00c3cf85d7 (diff)
downloadbrdo-1a91990cae84f045b774e0eb308334dea1e97b28.tar.gz
brdo-1a91990cae84f045b774e0eb308334dea1e97b28.tar.bz2
#599706 follow-up by JohnAlbin, sun: Regression: Restore consistency to theme_menu_local_tasks() theme function
Diffstat (limited to 'themes')
-rw-r--r--themes/garland/page.tpl.php4
-rw-r--r--themes/garland/template.php16
-rw-r--r--themes/seven/page.tpl.php10
-rw-r--r--themes/seven/style.css1
-rw-r--r--themes/seven/template.php8
5 files changed, 17 insertions, 22 deletions
diff --git a/themes/garland/page.tpl.php b/themes/garland/page.tpl.php
index 6dc50c2d5..448d21601 100644
--- a/themes/garland/page.tpl.php
+++ b/themes/garland/page.tpl.php
@@ -47,8 +47,8 @@
<h1<?php print $tabs ? ' class="with-tabs"' : '' ?>><?php print $title ?></h1>
<?php endif; ?>
<?php print render($title_suffix); ?>
- <?php if ($tabs): ?><h2 class="element-invisible"><?php print t('Primary tabs'); ?></h2><ul class="tabs primary"><?php print render($tabs) ?></ul></div><?php endif; ?>
- <?php if ($tabs2): ?><h2 class="element-invisible"><?php print t('Secondary tabs'); ?></h2><ul class="tabs secondary"><?php print render($tabs2) ?></ul><?php endif; ?>
+ <?php if ($tabs): ?><?php print render($tabs); ?></div><?php endif; ?>
+ <?php print render($tabs2); ?>
<?php print $messages; ?>
<?php print render($page['help']); ?>
<?php if ($action_links): ?><ul class="action-links"><?php print render($action_links); ?></ul><?php endif; ?>
diff --git a/themes/garland/template.php b/themes/garland/template.php
index 6c3fc446f..8021d7cdd 100644
--- a/themes/garland/template.php
+++ b/themes/garland/template.php
@@ -59,7 +59,13 @@ function garland_process_html(&$vars) {
* Override or insert variables into the page template.
*/
function garland_preprocess_page(&$vars) {
- $vars['tabs2'] = menu_secondary_local_tasks();
+ // Move secondary tabs into a separate variable.
+ $vars['tabs2'] = array(
+ '#theme' => 'menu_local_tasks',
+ '#secondary' => $vars['tabs']['#secondary'],
+ );
+ unset($vars['tabs']['#secondary']);
+
if (isset($vars['main_menu'])) {
$vars['primary_nav'] = theme('links__system_main_menu', array(
'links' => $vars['main_menu'],
@@ -139,11 +145,3 @@ function garland_preprocess_region(&$vars) {
$vars['classes_array'][] = 'clearfix';
}
}
-
-/**
- * Returns the rendered local tasks. The default implementation renders
- * them as tabs. Overridden to split the secondary tasks.
- */
-function garland_menu_local_tasks() {
- return menu_primary_local_tasks();
-}
diff --git a/themes/seven/page.tpl.php b/themes/seven/page.tpl.php
index 72fd6d02a..c8ff98abf 100644
--- a/themes/seven/page.tpl.php
+++ b/themes/seven/page.tpl.php
@@ -8,17 +8,11 @@
<h1 class="page-title"><?php print $title; ?></h1>
<?php endif; ?>
<?php print render($title_suffix); ?>
- <?php if ($primary_local_tasks): ?>
- <h2 class="element-invisible"><?php print t('Primary tabs'); ?></h2>
- <ul class="tabs primary"><?php print render($primary_local_tasks); ?></ul>
- <?php endif; ?>
+ <?php print render($primary_local_tasks); ?>
</div>
<div id="page">
- <?php if ($secondary_local_tasks): ?>
- <h2 class="element-invisible"><?php print t('Secondary tabs'); ?></h2>
- <ul class="tabs secondary"><?php print render($secondary_local_tasks); ?></ul>
- <?php endif; ?>
+ <?php print render($secondary_local_tasks); ?>
<div id="content" class="clearfix">
<div class="element-invisible"><a id="main-content"></a></div>
diff --git a/themes/seven/style.css b/themes/seven/style.css
index deca79bd9..df7f3de36 100644
--- a/themes/seven/style.css
+++ b/themes/seven/style.css
@@ -869,7 +869,6 @@ ol.task-list li.done {
background-color: #fff;
padding-top: 15px;
}
-.overlay .primary,
.overlay #branding h1.page-title,
.overlay #left,
.overlay #footer {
diff --git a/themes/seven/template.php b/themes/seven/template.php
index 78d41f168..0b0afc192 100644
--- a/themes/seven/template.php
+++ b/themes/seven/template.php
@@ -27,8 +27,12 @@ function seven_preprocess_html(&$vars) {
* Override or insert variables into the page template.
*/
function seven_preprocess_page(&$vars) {
- $vars['primary_local_tasks'] = menu_primary_local_tasks();
- $vars['secondary_local_tasks'] = menu_secondary_local_tasks();
+ $vars['primary_local_tasks'] = $vars['tabs'];
+ unset($vars['primary_local_tasks']['#secondary']);
+ $vars['secondary_local_tasks'] = array(
+ '#theme' => 'menu_local_tasks',
+ '#secondary' => $vars['tabs']['#secondary'],
+ );
}
/**