Commit bdd98def authored by Aaron Wells's avatar Aaron Wells
Browse files

Bug 1558361: Remove "_blank" from note block

Also setting the note block's form change checker state to
"dirty" by default, so that users will get a warning before
navigating away to the other page.

Change-Id: I20f586781df63e942a7a1c82e5e74fd5214c233f
parent eba99dc1
...@@ -128,6 +128,7 @@ class PluginBlocktypeTextbox extends PluginBlocktype { ...@@ -128,6 +128,7 @@ class PluginBlocktypeTextbox extends PluginBlocktype {
// of blocks containing the new artefact. // of blocks containing the new artefact.
$blockid = $instance->get('id'); $blockid = $instance->get('id');
return <<<EOF return <<<EOF
formchangemanager.setFormStateById('instconf', FORM_CHANGED);
function updateTextContent(a) { function updateTextContent(a) {
setNodeAttribute('instconf_title', 'value', a.title); setNodeAttribute('instconf_title', 'value', a.title);
if (typeof(tinyMCE) != 'undefined') { if (typeof(tinyMCE) != 'undefined') {
...@@ -383,7 +384,7 @@ EOF; ...@@ -383,7 +384,7 @@ EOF;
'managenotes' => array( 'managenotes' => array(
'type' => 'html', 'type' => 'html',
'class' => 'right hidden', 'class' => 'right hidden',
'value' => '<a href="' . $manageurl . '" target="_blank">' 'value' => '<a href="' . $manageurl . '">'
. get_string('managealltextboxcontent1', 'blocktype.internal/textbox') . ' &raquo;</a>', . get_string('managealltextboxcontent1', 'blocktype.internal/textbox') . ' &raquo;</a>',
), ),
'artefactid' => self::artefactchooser_element(isset($artefactid) ? $artefactid : null), 'artefactid' => self::artefactchooser_element(isset($artefactid) ? $artefactid : null),
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment