diff options
Diffstat (limited to 'content_scripts/mode.coffee')
| -rw-r--r-- | content_scripts/mode.coffee | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/content_scripts/mode.coffee b/content_scripts/mode.coffee index a69c90a7..2d28d95b 100644 --- a/content_scripts/mode.coffee +++ b/content_scripts/mode.coffee @@ -151,11 +151,11 @@ class Mode # case), because they do not need to be concerned with the value they yield. alwaysContinueBubbling: handlerStack.alwaysContinueBubbling - # Get a copy of the configuration options for this mode, but excluding the main keyboard-event handlers. - getConfigurationOptions: -> - options = extend {}, @options - delete options[key] for key in [ "keydown", "keypress", "keyup" ] - options + # Activate a new instance of this mode, together with all of its original options (except its main + # keybaord-event handlers; these will be recreated). + cloneMode: -> + delete @options[key] for key in [ "keydown", "keypress", "keyup" ] + new @constructor @options # Static method. Used externally and internally to initiate bubbling of an updateBadge event and to send # the resulting badge to the background page. We only update the badge if this document (hence this frame) |
