Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- element
- .bind('mouseover', function() {
- var selection = $window.getSelection();
- var range = $document[0].createRange();
- range.selectNodeContents(this);
- selection.removeAllRanges();
- selection.addRange(range);
- })
- .bind('mouseout', function() {
- $window.getSelection().removeAllRanges();
- })
- .bind('mousedown', function(event) {
- event.preventDefault();
- event.stopPropagation();
- return false;
- })
Advertisement
Add Comment
Please, Sign In to add comment