Dodanie przycisku reload.
[redakcja.git] / project / static / js / views / xml.js
index a1b6ca6..20e2ee9 100644 (file)
@@ -35,6 +35,8 @@ var XMLView = View.extend({
     $('.xmlview', this.element).height(height);
   },
   
+  reload: function() {},
+  
   editorDidLoad: function(editor) {
     $(editor.frame).css({width: '100%', height: '100%'});
     this.model
@@ -58,7 +60,6 @@ var XMLView = View.extend({
   },
   
   modelDataChanged: function(property, value) {
-    console.log('modelDataChanged');
     if (this.editor.getCode() != value) {
       this.editor.setCode(value);
     }
@@ -73,6 +74,8 @@ var XMLView = View.extend({
       this.freeze('Ɓadowanie...');
     } else if (value == 'saving') {
       this.freeze('Zapisywanie...');
+    } else if (value == 'error') {
+      this.freeze(this.model.get('error'));
     }
   },