diff options
| author | mrmr1993 | 2014-11-23 12:45:11 +0000 |
|---|---|---|
| committer | mrmr1993 | 2014-11-23 12:45:11 +0000 |
| commit | 3863e724241408338c9c69af72117584c1258d34 (patch) | |
| tree | d5b3bf01915d775065640902f8405ae8b32df55c /background_scripts | |
| parent | e7d3f29cb5e3bdcf55ab18c127564ebfbb4d5259 (diff) | |
| download | vimium-3863e724241408338c9c69af72117584c1258d34.tar.bz2 | |
Don't record frameIds for frames only containing a frameset
Frameset frames have no content of their own -- they only embed other
pages in sub-frames. The user can't perform any actions (of ours or
the browsers) with a frameset focused, so we might as well just not
focus it.
Diffstat (limited to 'background_scripts')
| -rw-r--r-- | background_scripts/main.coffee | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/background_scripts/main.coffee b/background_scripts/main.coffee index 0c969aed..aac63213 100644 --- a/background_scripts/main.coffee +++ b/background_scripts/main.coffee @@ -598,6 +598,7 @@ openOptionsPageInNewTab = -> registerFrame = (request, sender) -> frames = frameIdsForTab[sender.tab.id] ?= [] + return if request.is_frameset # Don't store frameset containers; focusing them is no use. if request.is_top frames.unshift request.frameId else @@ -609,7 +610,7 @@ unregisterFrame = (request, sender) -> if request.is_top # The whole tab is closing, so we can drop the frames list. updateOpenTabs sender.tab - else + else if not request.if_frameset index = frames.indexOf request.frameId return if index == -1 frames.splice index, 1 |
