+    var self =  this;    
+        
+    $.ajax({        
+        url: $('#commit-dialog form').attr('action'),
+        dataType: 'json',
+        success: function(data, textStatus) {
+            switch(data.result) {
+                case 'done':
+                    self.showPopup('generic-yes', 'Łączenie zmian powiodło się.');
+
+                    if(data.localmodified) {
+                        self.refreshPanels();
+                    }
+                        
+                    break;
+                case 'nothing-to-do':
+                    self.showPopup('generic-info', 'Brak zmian do połaczenia.');
+                    break;
+                default:
+                    self.showPopup('generic-error', data.errors && data.errors[0]);
+            }
+        },
+        error: function(rq, tstat, err) {
+            self.showPopup('generic-error', 'Błąd serwera: ' + err);
+        },
+        type: 'POST',
+        data: {
+            'message': message
+        }
+    }); 
+};
+
+Editor.prototype.postSplitRequest = function(s, f)
+{
+    $.ajax({
+        url: $('#split-dialog form').attr('action'),
+        dataType: 'html',
+        success: s,
+        error: f,
+        type: 'POST',
+        data: $('#split-dialog form').serialize()
+    });
+};
+
+
+Editor.prototype.allPanels = function() {
+    return $('#' + this.rootDiv.attr('id') +' > *.panel-wrap', this.rootDiv.parent());
+};