diff options
| author | Stephen Blott | 2015-01-02 10:24:39 +0000 | 
|---|---|---|
| committer | Stephen Blott | 2015-01-02 11:01:03 +0000 | 
| commit | 20ebbf3de2384738af916a441470d74a5aca14a3 (patch) | |
| tree | b477a0e03097e5368668dbe08a42e48dbd8db132 /lib | |
| parent | b5535bc5a1b44c12cff62bac601a8d6ec7e04a6c (diff) | |
| download | vimium-20ebbf3de2384738af916a441470d74a5aca14a3.tar.bz2 | |
Modes; rework badge handling and fix passkeys mode.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/handler_stack.coffee | 7 | 
1 files changed, 6 insertions, 1 deletions
| diff --git a/lib/handler_stack.coffee b/lib/handler_stack.coffee index 8929fa53..8de6ec12 100644 --- a/lib/handler_stack.coffee +++ b/lib/handler_stack.coffee @@ -26,7 +26,7 @@ class HandlerStack          @currentId = handler.id          passThrough = handler[type].call(@, event)          if not passThrough -          DomUtils.suppressEvent(event) +          DomUtils.suppressEvent(event) if @isChromeEvent event            return false          # If the constant @passDirectlyToPage is returned, then discontinue further bubbling and pass the          # event through to the underlying page.  The event is not suppresssed. @@ -41,5 +41,10 @@ class HandlerStack          @stack.splice(i, 1)          break +  # The handler stack handles chrome events (which may need to be suppressed) and internal (fake) events. +  # This checks whether that the event at hand is a chrome event. +  isChromeEvent: (event) -> +    event?.preventDefault? and event?.stopImmediatePropagation? +  root.HandlerStack = HandlerStack  root.handlerStack = new HandlerStack | 
