diff options
| author | Stephen Blott | 2015-01-17 05:51:52 +0000 | 
|---|---|---|
| committer | Stephen Blott | 2015-01-17 06:09:15 +0000 | 
| commit | 9cb0f2853a155e39270282e6ed224966afffc61e (patch) | |
| tree | d180bb45baea4a34be20db7512fff0851b89f706 /content_scripts/mode.coffee | |
| parent | cd49c88eaad6550ba768159347be6c88f1c26d15 (diff) | |
| download | vimium-9cb0f2853a155e39270282e6ed224966afffc61e.tar.bz2 | |
Modes; yet more tweaks...
- Mainly comments.
- Rename chooseBadge to updateBadge (for consistency).
- No badge for passkeys; also fix tests.
Diffstat (limited to 'content_scripts/mode.coffee')
| -rw-r--r-- | content_scripts/mode.coffee | 6 | 
1 files changed, 2 insertions, 4 deletions
diff --git a/content_scripts/mode.coffee b/content_scripts/mode.coffee index 6bd09af2..2ff71ca8 100644 --- a/content_scripts/mode.coffee +++ b/content_scripts/mode.coffee @@ -85,8 +85,8 @@ class Mode          "click": (event) => @alwaysContinueBubbling => @exit event      # Some modes are singletons: there may be at most one instance active at any time.  A mode is a singleton -    # if @options.singleton is truthy.  The value of @options.singleton should be the which is intended to -    # be unique.  New instances deactivate existing instances. +    # if @options.singleton is truthy.  The value of @options.singleton should be the key the which is +    # intended to be unique.  New instances deactivate existing instances with the same key.      if @options.singleton        do =>          singletons = Mode.singletons ||= {} @@ -94,8 +94,6 @@ class Mode          @onExit => delete singletons[key] if singletons[key] == @          if singletons[key]            @log "singleton:", "deactivating #{singletons[key].id}" -          # We're currently installing a new mode, so we'll be updating the badge shortly.  Therefore, we can -          # suppress badge updates while deactivating the existing singleton.  This can prevent badge flicker.            singletons[key].exit()          singletons[key] = @  | 
