From 486dce36493836461de7e9ae73721230ad69a1b5 Mon Sep 17 00:00:00 2001 From: Stephen Blott Date: Tue, 6 Jan 2015 13:32:34 +0000 Subject: Modes; fix PostFindMode for contentEditable. --- content_scripts/mode_find.coffee | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'content_scripts') diff --git a/content_scripts/mode_find.coffee b/content_scripts/mode_find.coffee index 0bcb0eb1..e11b2e0f 100644 --- a/content_scripts/mode_find.coffee +++ b/content_scripts/mode_find.coffee @@ -15,9 +15,10 @@ class PostFindMode extends InsertModeBlocker return @exit() unless element and findModeAnchorNode - # Special cases only arise if the active element is focusable. So, exit immediately if it is not. + # Special cases only arise if the active element can take input. So, exit immediately if it cannot not. canTakeInput = DomUtils.isSelectable(element) and DomUtils.isDOMDescendant findModeAnchorNode, element canTakeInput ||= element.isContentEditable + canTakeInput ||= findModeAnchorNode?.parentElement?.isContentEditable return @exit() unless canTakeInput self = @ -- cgit v1.2.3