Utwórz klasę stylu tak:
.unselectable {
-moz-user-select: none;
-khtml-user-select: none;
-webkit-user-select: none;
user-select: none;
-ms-user-select : none
}
Następnie zmienia Javascript lekko przypisać tej klasy na mousedown. Z tego niezmienionego scenariusza wyglądałoby to tak.
jQuery(function($){
//Initialise
iPhoneAnimation.init();
//Mouse down bind move event
$(".content-box").bind("mousedown", function(e){
$(this).bind("mousemove", iPhoneAnimation.moveInfo);
$(this).addClass("unselectable"); // <-- ADD THIS
});
//Unbind mouse event
$(".content-box").bind("mouseup", function(e){
var $this = $(this);
$this.unbind("mousemove", iPhoneAnimation.moveInfo);
//Animate the panel
iPhoneAnimation.panelAnimate($this);
//Reset the private var
iPhoneAnimation.resetVars();
$(this).removeClass("unselectable"); // <-- AND ADD THIS
});
});
wyłączania unosi trzeba rozpiąć zdarzenia na mousedown
tak:
$(this).unbind('mouseenter mouseleave');
Następnie ponownie powiązać je ponownie mouseup
jak wyżej.
że to zrobił, dzięki! – Wesley