jQuery('#test .track, :not(.btn)').mousemove(function(e){
var el = e.target;
jQuery(el).mouseover(function (e) {
e.stopPropagation();
jQuery(this).addClass('highlight');
jQuery(this).click(function(){
jQuery('.active').removeClass('active');
show_data(this); // a small function for showing this class, css
})
}).mouseout(function() {
jQuery(this).removeClass('highlight');
});
});
Этот код разбивает мой firefox при непрерывном нажатии. Я использую этот код, чтобы выделить текущий элемент DOM под мышью.jQuery - mousemove crashing my firefox
может быть, вы можете заменить JQuery с $. Это, по сути, одно и то же, но сделать коды лучше. – revolver
Ошибка типа: $ не является функцией – user007
Использование $ - не большая проблема, у вас есть 2 обработчика событий внутри mousemove. Может, в этом и проблема. – Praveen