aboutsummaryrefslogtreecommitdiffstats
path: root/content_scripts
diff options
context:
space:
mode:
authorStephen Blott2014-12-22 16:56:29 +0000
committerStephen Blott2014-12-22 16:56:29 +0000
commit99d784ff593378be41b5e6eb87867826fee9e921 (patch)
tree2e543eaafea025cc899944528173bc639634b5d0 /content_scripts
parentb422c6f905b6d768b2bc1eef0870388b7be1b34c (diff)
downloadvimium-99d784ff593378be41b5e6eb87867826fee9e921.tar.bz2
Add comment regarding .blur() on embeds.
Including embeds for .blur() etc. here is experimental. It appears to be the right thing to do for most common use cases. However, it could also cripple flash-based sites and games. See discussion in #1211 and #1194.
Diffstat (limited to 'content_scripts')
-rw-r--r--content_scripts/vimium_frontend.coffee3
1 files changed, 3 insertions, 0 deletions
diff --git a/content_scripts/vimium_frontend.coffee b/content_scripts/vimium_frontend.coffee
index eacba682..071e87a6 100644
--- a/content_scripts/vimium_frontend.coffee
+++ b/content_scripts/vimium_frontend.coffee
@@ -458,6 +458,9 @@ onKeydown = (event) ->
if isEditable(event.srcElement) or isEmbed(event.srcElement)
# Remove focus so the user can't just get himself back into insert mode by typing in the same input
# box.
+ # NOTE(smblott, 2014/12/22) Including embeds for .blur() etc. here is experimental. It appears to be
+ # the right thing to do for most common use cases. However, it could also cripple flash-based sites and
+ # games. See discussion in #1211 and #1194.
event.srcElement.blur()
exitInsertMode()
DomUtils.suppressEvent event