- };
-
- function xmleditor_onunload(event, panel) {}
-
- panel(xmleditor_onload, xmleditor_onunload);
-})();
+
+ $('.decrease-font-size', panel).click(function() {
+ var frameBody = $('body', $(texteditor.frame).contents());
+ console.log(frameBody.css('font-size'));
+ frameBody.css('font-size', parseInt(frameBody.css('font-size')) - 2);
+ });
+
+ $('.increase-font-size', panel).click(function() {
+ var frameBody = $('body', $(texteditor.frame).contents());
+ console.log(frameBody.css('font-size'));
+ frameBody.css('font-size', parseInt(frameBody.css('font-size')) + 2);
+ });
+ this.texteditor = texteditor;
+ },
+
+ unload: function() {
+ this.texteditor = null;
+ },
+
+
+ //refresh: function() { }, // no support for refresh
+
+ saveInfo: function(saveInfo) {
+ var myInfo = {
+ url: "{% url file_xml fpath %}",
+ postData: {
+ content: this.texteditor.getCode()
+ }
+ };
+ $.extend(saveInfo, myInfo);
+ }
+};
+