+
-
Index: modules/system/region.tpl.php
===================================================================
RCS file: modules/system/region.tpl.php
diff -N modules/system/region.tpl.php
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ modules/system/region.tpl.php 13 Aug 2009 05:53:22 -0000
@@ -0,0 +1,32 @@
+
+
+
+
Index: modules/system/system.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.module,v
retrieving revision 1.743
diff -u -p -r1.743 system.module
--- modules/system/system.module 12 Aug 2009 23:51:19 -0000 1.743
+++ modules/system/system.module 13 Aug 2009 05:53:22 -0000
@@ -2977,6 +2977,26 @@ function theme_system_compact_link() {
return $output;
}
+/**
+ * Implement hook_page_alter().
+ *
+ * Render regions.
+ */
+function system_page_alter($page) {
+ global $theme;
+
+ // Find all block regions.
+ $regions = system_region_list($theme);
+
+ // Load all region content assigned via blocks.
+ foreach (array_keys($regions) as $region) {
+ // Don't render empty regions.
+ if (!empty($page[$region])) {
+ $page[$region]['#theme_wrappers'][] = 'region';
+ $page[$region]['#region'] = $region;
+ }
+ }
+}
/**
* Send Drupal and the major version number in the META GENERATOR HTML.
Index: themes/garland/page.tpl.php
===================================================================
RCS file: /cvs/drupal/drupal/themes/garland/page.tpl.php,v
retrieving revision 1.31
diff -u -p -r1.31 page.tpl.php
--- themes/garland/page.tpl.php 3 Aug 2009 03:04:34 -0000 1.31
+++ themes/garland/page.tpl.php 13 Aug 2009 05:53:22 -0000
@@ -17,7 +17,7 @@
-
+
Index: themes/garland/style-rtl.css
===================================================================
RCS file: /cvs/drupal/drupal/themes/garland/style-rtl.css,v
retrieving revision 1.15
diff -u -p -r1.15 style-rtl.css
--- themes/garland/style-rtl.css 6 Aug 2009 05:06:00 -0000 1.15
+++ themes/garland/style-rtl.css 13 Aug 2009 05:53:22 -0000
@@ -72,7 +72,7 @@ dl dd {
margin: 2em 0 1em 0.5em;
}
-#header-region h2 {
+.region-header h2 {
margin: 0 0 0 1em;
}
Index: themes/garland/style.css
===================================================================
RCS file: /cvs/drupal/drupal/themes/garland/style.css,v
retrieving revision 1.62
diff -u -p -r1.62 style.css
--- themes/garland/style.css 6 Aug 2009 05:06:00 -0000 1.62
+++ themes/garland/style.css 13 Aug 2009 05:53:22 -0000
@@ -293,17 +293,17 @@ table .form-button, table .form-submit {
/**
* Layout
*/
-#header-region {
+.region-header {
min-height: 1em;
background: #d2e6f3 url(images/bg-navigation.png) repeat-x 50% 100%;
}
-#header-region .block {
+.region-header .block {
display: block;
margin: 0 1em;
}
-#header-region .block-region {
+.region-header .block-region {
display: block;
margin: 0 0.5em 1em;
padding: 0.5em;
@@ -311,7 +311,7 @@ table .form-button, table .form-submit {
top: 0.5em;
}
-#header-region * {
+.region-header * {
display: inline;
line-height: 1.5em;
margin-top: 0;
@@ -319,19 +319,19 @@ table .form-button, table .form-submit {
}
/* Prevent the previous directive from showing the content of script elements in Mozilla browsers. */
-#header-region script {
+.region-header script {
display: none;
}
-#header-region p, #header-region img {
+.region-header p, .region-header img {
margin-top: 0.5em;
}
-#header-region h2 {
+.region-header h2 {
margin: 0 1em 0 0; /* LTR */
}
-#header-region h3, #header-region label, #header-region li {
+.region-header h3, .region-header label, .region-header li {
margin: 0 1em;
padding: 0;
background: none;
Index: themes/garland/template.php
===================================================================
RCS file: /cvs/drupal/drupal/themes/garland/template.php,v
retrieving revision 1.23
diff -u -p -r1.23 template.php
--- themes/garland/template.php 28 Jul 2009 10:09:25 -0000 1.23
+++ themes/garland/template.php 13 Aug 2009 05:53:22 -0000
@@ -44,6 +44,15 @@ function garland_preprocess_page(&$vars)
}
/**
+ * Override or insert variables into the region template.
+ */
+function garland_preprocess_region(&$vars) {
+ if ($vars['region'] = 'header') {
+ $vars['classes_array'][] = 'clearfix';
+ }
+}
+
+/**
* Returns the rendered local tasks. The default implementation renders
* them as tabs. Overridden to split the secondary tasks.
*/