JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
whitespace cleanup
authorJason Woofenden <jason@jasonwoof.com>
Thu, 18 May 2017 16:10:26 +0000 (12:10 -0400)
committerJason Woofenden <jason@jasonwoof.com>
Thu, 18 May 2017 16:10:26 +0000 (12:10 -0400)
editor.js

index 85c8f10..104bbae 100644 (file)
--- a/editor.js
+++ b/editor.js
@@ -825,39 +825,37 @@ function PeachHTML5Editor (in_el, options) {
        if (this.options.editor_id != null) {
                this.outer_iframe.setAttribute('id', this.options.editor_id)
        }
-       this.outer_iframe.onload = (function(_this) {
-               return function() {
-                       var icss
-                       _this.outer_idoc = _this.outer_iframe.contentDocument
-                       icss = domify(_this.outer_idoc, { style: { children: [
-                               domify(_this.outer_idoc, {text: css})
-                       ]}})
-                       _this.outer_idoc.head.appendChild(icss)
-                       _this.iframe = domify(_this.outer_idoc, {iframe: {sandbox: 'allow-same-origin allow-scripts'}})
-                       _this.iframe.onload = function() {
+       this.outer_iframe.onload = (function(_this) { return function() {
+               var icss
+               _this.outer_idoc = _this.outer_iframe.contentDocument
+               icss = domify(_this.outer_idoc, { style: { children: [
+                       domify(_this.outer_idoc, {text: css})
+               ]}})
+               _this.outer_idoc.head.appendChild(icss)
+               _this.iframe = domify(_this.outer_idoc, {iframe: {sandbox: 'allow-same-origin allow-scripts'}})
+               _this.iframe.onload = function() {
+                       return _this.init_1()
+               }
+               timeout(200, function() { // firefox never fires this onload
+                       if (!_this.init_1_called) {
                                return _this.init_1()
                        }
-                       timeout(200, function() { // firefox never fires this onload
-                               if (!_this.init_1_called) {
-                                       return _this.init_1()
-                               }
-                       })
-                       _this.outer_idoc.body.appendChild(
-                               domify(_this.outer_idoc, {div: {id: 'wrap1', children: [
-                                       domify(_this.outer_idoc, {div: {
-                                               style: "position: absolute; top: 0; left: 1px; font-size: 10px",
-                                               children: [domify(_this.outer_idoc, {text: "Peach HTML5 Editor"})]
-                                       }}),
-                                       _this.wrap2 = domify(_this.outer_idoc, {div: {id: 'wrap2', children: [
-                                               domify(_this.outer_idoc, {div: {id: 'wrap3', children: [
-                                                       _this.iframe,
-                                                       _this.overlay = domify(_this.outer_idoc, { div: { id: 'overlay' }})
-                                               ]}})
+               })
+               _this.outer_idoc.body.appendChild(
+                       domify(_this.outer_idoc, {div: {id: 'wrap1', children: [
+                               domify(_this.outer_idoc, {div: {
+                                       style: "position: absolute; top: 0; left: 1px; font-size: 10px",
+                                       children: [domify(_this.outer_idoc, {text: "Peach HTML5 Editor"})]
+                               }}),
+                               _this.wrap2 = domify(_this.outer_idoc, {div: {id: 'wrap2', children: [
+                                       domify(_this.outer_idoc, {div: {id: 'wrap3', children: [
+                                               _this.iframe,
+                                               _this.overlay = domify(_this.outer_idoc, { div: { id: 'overlay' }})
                                        ]}})
                                ]}})
-                       )
-               }
-       })(this)
+                       ]}})
+               )
+       }})(this)
        outer_wrap = domify(document, {div: {"class": 'peach_html5_editor' }})
        this.in_el.parentNode.appendChild(outer_wrap)
        outer_bounds = get_el_bounds(outer_wrap)