New maps in progress... (pop-up window to nodes)

This commit is contained in:
Arturo Gonzalez 2016-02-09 16:33:36 +01:00
parent 4c894fd04a
commit ef1d7e22bc
1 changed files with 14 additions and 4 deletions

View File

@ -57,7 +57,7 @@ MapController.prototype.click_event = function(event) {
switch (event.which) {
case 1:
if ($(event.currentTarget).attr("class") == "node") {
self.popup_map();
self.popup_map(self, event);
}
break;
case 2:
@ -69,6 +69,16 @@ MapController.prototype.click_event = function(event) {
}
}
MapController.prototype.popup_map = function() {
//POP-UP
MapController.prototype.popup_map = function(self, event) {
//console.log($(self._target + " svg"));
//console.log(event);
var xPos = event.pageX;
var YPos = event.pageY;
$(self._target + " svg").after($("<div>").attr("id", "dialog_popup"));
$("#dialog_popup").dialog({
modal: false,
title: "Ventana Modarrrrl!!",
resizable: false,
position: [xPos,YPos]
});
}