MDL-40167 dock: tidy up after first peer-review

This commit is contained in:
Sam Hemelryk
2013-07-15 09:46:03 +12:00
parent 84192d7836
commit a69a7e89b8
15 changed files with 834 additions and 635 deletions
+4
View File
@@ -446,6 +446,9 @@ class block_manager {
throw new coding_exception('block_manager has already prepared the blocks in region ' .
$region . 'for output. It is too late to add a fake block.');
}
if (!isset($bc->attributes['data-block'])) {
$bc->attributes['data-block'] = '_fake';
}
$this->extracontent[$region][] = $bc;
}
@@ -1860,6 +1863,7 @@ function block_add_block_ui($page, $output) {
$bc = new block_contents();
$bc->title = get_string('addblock');
$bc->add_class('block_adminblock');
$bc->attributes['data-block'] = 'adminblock';
$missingblocks = $page->blocks->get_addable_blocks();
if (empty($missingblocks)) {