data-id attribute for plots and areas's nodes

This commit is contained in:
Vincent Broute
2013-09-22 13:21:04 +02:00
parent 01592a72fd
commit 09e413f34f

View File

@ -236,7 +236,7 @@
$.fn.mapael.setHoverOptions(elem.textElem, options.textAttrs, options.textAttrsHover);
$.fn.mapael.setHover(paper, elem.mapElem, elem.textElem);
options.eventHandlers && $.fn.mapael.setEventHandlers(id, options, elem.mapElem, elem.textElem);
$(elem.textElem.node).attr('class', id);
$(elem.textElem.node).attr('data-id', id);
} else {
$.fn.mapael.setHover(paper, elem.mapElem);
options.eventHandlers && $.fn.mapael.setEventHandlers(id, options, elem.mapElem);
@ -255,7 +255,7 @@
if (typeof options.value != "undefined")
elem.value = options.value;
$(elem.mapElem.node).attr('class', id);
$(elem.mapElem.node).attr('data-id', id);
}
/**