Handling text selection event in Firefox extension (preventing user from selecting text)
问题 I was wondering if in chrome code we have some better way to detect when the user selects/highlights something in the current page than listening for keyup / mouseup and checking window.getSelection() . Any ideas? edit: Actually, what I'm trying to do is simply preventing the user from selecting any text at all in the contentDocument. Something that accomplishes this will be fine as well. (The idea behind getting the selection event was just to preventDefault() or otherwise getSelection()