I want to show the overlay over the div. After showing overlay i don't want to allow to select that background div. But when i double click on the over lay that background div is in selectable state. Can you please any one look into this. http://jsfiddle.net/fkWn5/2/
Solution
You can do this by using the user select rules in css and adding this class to the background element once turning on the overlay:
css:
.unselectable {
-moz-user-select: -moz-none;
-khtml-user-select: none;
-webkit-user-select: none;
-ms-user-select: none;
user-select: none;
}
adding the class with jquery:
$('#backgrounddiv').addClass('unselectable');
jsfiddle example:
References:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With