summaryrefslogtreecommitdiff
path: root/src/static/js
diff options
context:
space:
mode:
authorJohn McLear <john@mclear.co.uk>2012-04-20 15:10:40 -0700
committerJohn McLear <john@mclear.co.uk>2012-04-20 15:10:40 -0700
commita5210ab27d96d7d04e5ee1c0e3542d1c398db267 (patch)
tree5b35f22e25138b164a282eed4e9ca9d14f3d0db4 /src/static/js
parentb6be00c3ab9a068e5cb08b49e7ef2af740772cc7 (diff)
parentda75b87d3c90ecd27dfe9d1f8b583e9db38de7a7 (diff)
downloadetherpad-lite-a5210ab27d96d7d04e5ee1c0e3542d1c398db267.zip
Merge pull request #647 from etinquis/fixes
Fix + New Hook
Diffstat (limited to 'src/static/js')
-rw-r--r--src/static/js/ace.js8
-rw-r--r--src/static/js/domline.js4
2 files changed, 11 insertions, 1 deletions
diff --git a/src/static/js/ace.js b/src/static/js/ace.js
index 6ea2938b..85801d33 100644
--- a/src/static/js/ace.js
+++ b/src/static/js/ace.js
@@ -167,7 +167,13 @@ require.setGlobalKeyPath("require");\n\
buffer.push(Ace2Editor.EMBEDED[KERNEL_SOURCE]);
buffer.push(KERNEL_BOOT);
buffer.push('<\/script>');
- }
+ } else {
+ file = KERNEL_SOURCE;
+ buffer.push('<script type="application/javascript" src="' + KERNEL_SOURCE + '"><\/script>');
+ buffer.push('<script type="text/javascript">');
+ buffer.push(KERNEL_BOOT);
+ buffer.push('<\/script>');
+ }
}
function pushScriptsTo(buffer) {
/* Folling is for packaging regular expression. */
diff --git a/src/static/js/domline.js b/src/static/js/domline.js
index 5d8bb719..1be0f4ee 100644
--- a/src/static/js/domline.js
+++ b/src/static/js/domline.js
@@ -229,6 +229,10 @@ domline.createDomLine = function(nonEmpty, doesWrap, optBrowser, optDocument)
result.node.innerHTML = curHTML;
}
if (lineClass !== null) result.node.className = lineClass;
+
+ hooks.callAll("acePostWriteDomLineHTML", {
+ node: result.node
+ });
}
result.prepareForAdd = writeHTML;
result.finishUpdate = writeHTML;