Skip to content

Commit

Permalink
Fix bug with EpicEditor integration. Fixes #92
Browse files Browse the repository at this point in the history
  • Loading branch information
jdorn committed Apr 27, 2014
1 parent a5c936f commit 6342626
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 10 deletions.
7 changes: 3 additions & 4 deletions dist/jsoneditor.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! JSON Editor v0.6.3 - JSON Schema -> HTML Editor
/*! JSON Editor v0.6.4 - JSON Schema -> HTML Editor
* By Jeremy Dorn - https://github.com/jdorn/json-editor/
* Released under the MIT license
*
Expand Down Expand Up @@ -2124,19 +2124,18 @@ JSONEditor.defaults.editors.string = JSONEditor.AbstractEditor.extend({
clientSideStorage: false
});

this.epiceditor = new EpicEditor(options);
this.epiceditor = new EpicEditor(options).load();

this.epiceditor.importFile(null,this.getValue());

this.epiceditor.on('update',function() {
var val = self.epiceditor.exportFile();
self.input.value = val;
self.value = val;
if(self.parent) self.parent.onChildEditorChange(self);
else self.jsoneditor.onChange();
self.jsoneditor.notifyWatchers(self.path);
});

this.epiceditor.load();
}
// ACE editor for everything else
else if(window.ace) {
Expand Down
4 changes: 2 additions & 2 deletions dist/jsoneditor.min.js

Large diffs are not rendered by default.

5 changes: 2 additions & 3 deletions src/editors/string.js
Original file line number Diff line number Diff line change
Expand Up @@ -353,19 +353,18 @@ JSONEditor.defaults.editors.string = JSONEditor.AbstractEditor.extend({
clientSideStorage: false
});

this.epiceditor = new EpicEditor(options);
this.epiceditor = new EpicEditor(options).load();

this.epiceditor.importFile(null,this.getValue());

this.epiceditor.on('update',function() {
var val = self.epiceditor.exportFile();
self.input.value = val;
self.value = val;
if(self.parent) self.parent.onChildEditorChange(self);
else self.jsoneditor.onChange();
self.jsoneditor.notifyWatchers(self.path);
});

this.epiceditor.load();
}
// ACE editor for everything else
else if(window.ace) {
Expand Down
2 changes: 1 addition & 1 deletion src/intro.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! JSON Editor v0.6.3 - JSON Schema -> HTML Editor
/*! JSON Editor v0.6.4 - JSON Schema -> HTML Editor
* By Jeremy Dorn - https://github.com/jdorn/json-editor/
* Released under the MIT license
*
Expand Down

0 comments on commit 6342626

Please sign in to comment.