MDL-71610 theme_boost: remove edit button from Boost

This commit is contained in:
Bas Brands 2021-07-06 10:19:09 +02:00
parent 09f6ce9fed
commit a0bb51622c
12 changed files with 22 additions and 9 deletions

View file

@ -32,6 +32,9 @@ defined('MOODLE_INTERNAL') || die;
class core_renderer extends \core_renderer {
public function edit_button(moodle_url $url) {
if ($this->page->theme->haseditswitch) {
return;
}
$url->param('sesskey', sesskey());
if ($this->page->user_is_editing()) {
$url->param('edit', 'off');

View file

@ -157,3 +157,4 @@ $THEME->rendererfactory = 'theme_overridden_renderer_factory';
$THEME->requiredblocks = '';
$THEME->addblockposition = BLOCK_ADDBLOCK_POSITION_FLATNAV;
$THEME->iconsystem = \core\output\icon_system::FONTAWESOME;
$THEME->haseditswitch = true;

View file

@ -157,3 +157,4 @@ $THEME->scss = function($theme) {
};
$THEME->usefallback = true;
$THEME->iconsystem = '\\theme_classic\\output\\icon_system_fontawesome';
$THEME->haseditswitch = false;