From 3a31ddea2b516cebe60c6ac096516db8df101fd0 Mon Sep 17 00:00:00 2001 From: friendica Date: Wed, 16 Jul 2014 01:07:00 -0700 Subject: provide os_mkdir to workaround permission issues with php mkdir --- library/bbedit/editor.js | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) (limited to 'library') diff --git a/library/bbedit/editor.js b/library/bbedit/editor.js index 57de38876..563472ff5 100644 --- a/library/bbedit/editor.js +++ b/library/bbedit/editor.js @@ -27,6 +27,44 @@ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ + + + +function REDITOR(elm,wysiwyg) { + + this.elm = elm; + this.wysiwyg = wysiwyg; + + + +} + +REDITOR.prototype.showEditor = function() { + if (! this.enableWysiwyg) return; + this.editorVisible = true; + this.content = document.getElementById(this.body_id).value; + this.myeditor = this.ifm.contentWindow.document; + bbcode2html(); + this.myeditor.designMode = "on"; + this.myeditor.open(); + this.myeditor.write(''); + this.myeditor.write(''); + this.myeditor.write(content); + this.myeditor.write(''); + this.myeditor.close(); + if (this.myeditor.attachEvent) { + if(parent.ProcessKeyPress) + this.myeditor.attachEvent("onkeydown", parent.ProcessKeyPress); + this.myeditor.attachEvent("onkeypress", kp); + } + else if (this.myeditor.addEventListener) { + if (parent.ProcessKeyPress) + this.myeditor.addEventListener("keydown", parent.ProcessKeyPress, true); + this.myeditor.addEventListener("keypress",kp,true); + } +} + + var myeditor, ifm; var body_id, textboxelement; var content; -- cgit v1.2.3