Commit 65169b4b authored by George Popoff's avatar George Popoff

add alertify library to display notifications

parent 7fc4e957
...@@ -217,6 +217,12 @@ ETYPOS.prototype = { ...@@ -217,6 +217,12 @@ ETYPOS.prototype = {
self.isDragged = false; self.isDragged = false;
}); });
document.addEventListener("keyup", function(e) {
if ( e.keyCode === 27 ) {
self.closeWindow();
}
});
document.addEventListener("mousemove", function (e) { document.addEventListener("mousemove", function (e) {
if (self.isDragged && self.isVisible && (e.buttons & 1)) { if (self.isDragged && self.isVisible && (e.buttons & 1)) {
self.box_x = (self.lastBoxPos.x + (e.clientX - self.lastMousePos.x)); self.box_x = (self.lastBoxPos.x + (e.clientX - self.lastMousePos.x));
...@@ -453,6 +459,10 @@ ETYPOS.prototype = { ...@@ -453,6 +459,10 @@ ETYPOS.prototype = {
this_object.storeTypo(form_data.get("text"), form_data.get("comment")); this_object.storeTypo(form_data.get("text"), form_data.get("comment"));
this_object.fixTypos(); this_object.fixTypos();
this_object.closeWindow();
alertify.success(response['message']);
} else { } else {
var success = 'error'; var success = 'error';
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment