diff options
| author | Stephen Blott | 2016-04-13 06:50:43 +0100 | 
|---|---|---|
| committer | Stephen Blott | 2016-04-13 06:50:43 +0100 | 
| commit | 72ff4204655b8e87f7bdfbe8c9974376fbbc15a6 (patch) | |
| tree | 0cf92a9f1484666294b7a329919e598efac6e5cc /lib/handler_stack.coffee | |
| parent | f144c7c9d3f141636ce6a3856db3abf08a4fc063 (diff) | |
| download | vimium-72ff4204655b8e87f7bdfbe8c9974376fbbc15a6.tar.bz2 | |
Add <c-y> and <c-e> for visual mode.
Fixes #2092.
Diffstat (limited to 'lib/handler_stack.coffee')
| -rw-r--r-- | lib/handler_stack.coffee | 23 | 
1 files changed, 12 insertions, 11 deletions
| diff --git a/lib/handler_stack.coffee b/lib/handler_stack.coffee index c17be24f..806b707f 100644 --- a/lib/handler_stack.coffee +++ b/lib/handler_stack.coffee @@ -93,20 +93,21 @@ class HandlerStack      @continueBubbling    alwaysSuppressPropagation: (handler = null) -> -    handler?() -    @suppressPropagation +    if handler?() == @suppressEvent then @suppressEvent else @suppressPropagation    # Debugging.    logResult: (eventNumber, type, event, handler, result) -> -    label = -      switch result -        when @passEventToPage then "passEventToPage" -        when @suppressPropagation then "suppressPropagation" -        when @restartBubbling then "restartBubbling" -        when "skip" then "skip" -        when true then "continue" -    label ||= if result then "continue/truthy" else "suppress" -    console.log "#{eventNumber}", type, handler._name, label +    if event?.type == "keydown" # Tweak this as needed. +      label = +        switch result +          when @passEventToPage then "passEventToPage" +          when @suppressEvent then "suppressEvent" +          when @suppressPropagation then "suppressPropagation" +          when @restartBubbling then "restartBubbling" +          when "skip" then "skip" +          when true then "continue" +      label ||= if result then "continue/truthy" else "suppress" +      console.log "#{eventNumber}", type, handler._name, label    show: ->      console.log "#{@eventNumber}:" | 
