summaryrefslogtreecommitdiff
path: root/modules/block
diff options
context:
space:
mode:
Diffstat (limited to 'modules/block')
-rw-r--r--modules/block/block-admin-display-form.tpl.php4
-rw-r--r--modules/block/block.css2
-rw-r--r--modules/block/block.test14
3 files changed, 10 insertions, 10 deletions
diff --git a/modules/block/block-admin-display-form.tpl.php b/modules/block/block-admin-display-form.tpl.php
index 5195f4af1..f7c9b1cf6 100644
--- a/modules/block/block-admin-display-form.tpl.php
+++ b/modules/block/block-admin-display-form.tpl.php
@@ -45,8 +45,8 @@
<tbody>
<?php $row = 0; ?>
<?php foreach ($block_regions as $region => $title): ?>
- <tr class="region region-<?php print $region?>">
- <td colspan="5" class="region"><?php print $title; ?></td>
+ <tr class="region-title region-title-<?php print $region?>">
+ <td colspan="5"><?php print $title; ?></td>
</tr>
<tr class="region-message region-<?php print $region?>-message <?php print empty($block_listing[$region]) ? 'region-empty' : 'region-populated'; ?>">
<td colspan="5"><em><?php print t('No blocks in this region'); ?></em></td>
diff --git a/modules/block/block.css b/modules/block/block.css
index 3d579ee6c..56ba1c560 100644
--- a/modules/block/block.css
+++ b/modules/block/block.css
@@ -1,6 +1,6 @@
/* $Id$ */
-#blocks td.region {
+#blocks tr.region-title td {
font-weight: bold;
}
#blocks tr.region-message {
diff --git a/modules/block/block.test b/modules/block/block.test
index 085d5c36a..02b774ca8 100644
--- a/modules/block/block.test
+++ b/modules/block/block.test
@@ -26,10 +26,10 @@ class BlockTestCase extends DrupalWebTestCase {
// Define the existing regions
$this->regions = array();
- $this->regions[] = array('name' => 'header', 'id' => 'header-region');
- $this->regions[] = array('name' => 'sidebar_first', 'id' => 'sidebar-first');
- $this->regions[] = array('name' => 'content', 'id' => 'center');
- $this->regions[] = array('name' => 'sidebar_second', 'id' => 'sidebar-second');
+ $this->regions[] = array('name' => 'header', 'class' => 'region region-header clearfix');
+ $this->regions[] = array('name' => 'sidebar_first');
+ $this->regions[] = array('name' => 'content');
+ $this->regions[] = array('name' => 'sidebar_second');
$this->regions[] = array('name' => 'footer');
}
@@ -193,8 +193,8 @@ class BlockTestCase extends DrupalWebTestCase {
function moveBlockToRegion($block, $region) {
// If an id for an region hasn't been specified, we assume it's the same as the name.
- if (!(isset($region['id']))) {
- $region['id'] = $region['name'];
+ if (!(isset($region['class']))) {
+ $region['class'] = 'region region-' . str_replace('_', '-', $region['name']);
}
// Set the created block to a specific region.
@@ -209,7 +209,7 @@ class BlockTestCase extends DrupalWebTestCase {
$this->assertText(t($block['title']), t('Block successfully being displayed on the page.'));
// Confirm that the custom block was found at the proper region.
- $xpath = '//div[@id="' . $region['id'] . '"]//div[@id="block-' . $block['module'] . '-' . $block['delta'] . '"]/*';
+ $xpath = '//div[@class="' . $region['class'] . '"]//div[@id="block-' . $block['module'] . '-' . $block['delta'] . '"]/*';
$this->assertFieldByXPath($xpath, FALSE, t('Custom block found in %region_name region.', array('%region_name' => $region['name'])));
}
}