aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2016-03-01Refactor hints; add `userMightOverType`.Stephen Blott
Previously, we set a variable `delay` and then did some logical gymnastics to get the correct effect. However, in fact, all we care about is whether the user might over-type the links text. So changing to using that as a Boolean flag greatly simplifies the logic. And we lose about 10 LoC.
2016-03-01Refactor hints; consistent variable naming.Stephen Blott
While we're changing this code, we can renamed the parameter here to be consistent with its naming elsewhere.
2016-03-01Refactor hints; remove trailing whitespace.Stephen Blott
Somehow,
2016-03-01Refactor hints; remove legacy code.Stephen Blott
Previously (quite some time ago) we reused the LinkHints object. But for some time it's been a class, and we never reuse instances. Therefore, we can remove the code related to resetting the object's state.
2016-03-01Refactor hints; fix exit sequence.Stephen Blott
Previously, the exit sequence when a link was "clicked" was spread over several functions with several callbacks. This made it difficult to verify that the correct actions were happening in the correct order. Indeed, they weren't in at least one case (we were still showing hints while "waiting for enter"). This fixes that by putting all of the various deactivation orders into one place, `@activateLink()`, and simplifies `@deactivateMode()` accordingle.
2016-02-28Remove some legacy (and unused) code.Stephen Blott
2016-02-28Fix for <count>F.Stephen Blott
We were immediately restarting link-hints mode if a count was present. Unfortunately, that meant that we were detecting our own link-hint click and exiting immediately. So, with a count of 6, we were only getting 3 link-hint activations. To avoid this, we add a short delay (just nextTick). Also, move some other stuff arund to make sure this works in all cases (e.g. wait-for-enter).
2016-02-28Fix defualt command "options".Stephen Blott
The default (for when no options are provided) is of the wrong type. This works as is, but should really be fixed -- as here.
2016-02-28Merge pull request #2026 from smblott-github/fix-2023Stephen Blott
Refactor focusFrame - Fix #2023.
2016-02-28Merge pull request #2025 from smblott-github/pass-count-to-scroll-functionsStephen Blott
Pass to count to scroll commands.
2016-02-28Refactor focusFrame.Stephen Blott
Only the `flashFrame` part needs to be guarded against the DOM being ready. So we can take the `flashFrame` part out as a regular function. Fixes #2023 (although I don't fully understand why that's happening).
2016-02-28Merge pull request #2014 from smblott-github/record-install-dateStephen Blott
Add install date to logging page.
2016-02-28Pass to count to scroll commands.Stephen Blott
Currently, `10j` keeping `j` held down scrolls quickly for a time then reduces back the regular hold-`j` scroll speed. Therefore, the user cannot use a count to influence the smooth-scrolling scroll speed. This PR fixes that by passing the count to the scroll functions. Consequently, we adjust the actual scroll amount (which affects the scroll speed) rather than calling the scroll commands several times (which doesn't).
2016-02-27Remove unnecessary vomnibar click code.Stephen Blott
This is no longer necessary since the help page is in an iframe.
2016-02-27Merge pull request #2021 from mrmr1993/click-the-same-wayStephen Blott
Make behaviour match LinkHints for goPrevious and goNext
2016-02-27Merge pull request #2020 from mrmr1993/remove-old-redundant-exclusionsStephen Blott
Remove outdated blacklist in DomUtils.isEditable, use DomUtils.isSelectable
2016-02-26Change followLink to use the same method as LinkHints clickingmrmr1993
2016-02-26Don't try to evaluate DomUtils.isSelectable on non-elementsmrmr1993
This stops us from throwing errors when document, window, etc. end up being passed into DomUtils.isSelectable.
2016-02-26Remove outdated blacklist in DomUtils.isEditable, use .isSelectablemrmr1993
This fixes #1964.
2016-02-23Tweak #2015.Stephen Blott
2016-02-23Workaround for the hanging part of issue #1944 "Tests fail/hang with latest ↵stephane
PhantomJS (2.1.1)". URL: https://github.com/philc/vimium/issues/1944
2016-02-22Format branch better on logging pagemrmr1993
2016-02-22Include branch information in the logging pagemrmr1993
2016-02-22Correct name on the logging page.Stephen Blott
Oversight from #1958.
2016-02-22Remove legacy reference to edit mode.Stephen Blott
Omitted from #1961.
2016-02-22Add install date to logging page; remove console.log.Stephen Blott
2016-02-22Add install date to logging page.Stephen Blott
This implements a poor-man's build info. See #1352. Unfortunately, that requires a separate build target, and does not work with `cake autobuild`. This just records the *install date* and displays that info on the logging page. "Install date" because we can reliably determine it, and because it does answer the question *have I upgrade Vimium on this machine since last week?*. And on the logging page because that's out of the way, and not part of the regular Vimium interface.
2016-02-21Fix divide by zero.Stephen Blott
If text.length is 1, here, then we divide by `log 1` - which is zero. So add one.
2016-02-21Include count command option in repeat limit.Stephen Blott
We need to multiply by `count=N` *before* checking `repeatLimit`. Tweaks #2001.
2016-02-21Remove selectionChangedHandlers.Stephen Blott
With #2006 and #2009, this is no longer being used.
2016-02-21Merge pull request #2004 from smblott-github/remove-tabInfoMapStephen Blott
Remove (unused) `tabInfoMap`.
2016-02-21Merge branch 'rework-duplicateTab'Stephen Blott
Conflicts: background_scripts/commands.coffee
2016-02-21Merge pull request #2006 from smblott-github/fix-removeTabStephen Blott
Fix `<count>removeTab`.
2016-02-21Rework count command option initialisation.Stephen Blott
Previously: map J scrollDown count=NotANumber would break the command completely. Fixes an error introduced in #2001.
2016-02-20Merge pull request #2010 from mrmr1993/fix-find-historyStephen Blott
Use for (not for own) when iterating over an event's properties
2016-02-20Use for (not for own) when iterating over an event's propertiesmrmr1993
Moving to for own broke find mode history (and thus also next/previous). This reverts that part of commit 56fed2ac6663d99ca03023f3ffa313c51de5fe32.
2016-02-20Rework the `duplicateTab` implementation...Stephen Blott
Specifically, avoid reliance on `chrome.tabs.onSelectionChanged`. If we merge this and #2006, then we can delete all of the `chrome.tabs.onSelectionChanged` code.
2016-02-20Merge branch 'windows-onFocusChanged'Stephen Blott
2016-02-20Tweak #2007.Stephen Blott
2016-02-21fix a crash of unit testsgdh1995
2016-02-20Fix bug in #2001.Stephen Blott
We were incorrectly setting `options.count` to `NaN` if there was no command option.
2016-02-21use chrome.windows.onFocusChanged to listen window switchinggdh1995
This fix the problem that `chrome.tabs.onActivated` won't be triggered when we switch Chrome windows.
2016-02-20Fix `<count>removeTab`.Stephen Blott
There's a nasty little bug in `removeTab` when you remove more tabs than there are in the window (and there is a second window): - all of the tabs in the currently-focused window are removed - then, later (so, time passes), when you change tab in the other window, we begin removing tabs again! The source of the bug is our reliance on `chrome.tabs.onSelectionChanged`, which doesn't first when removing the last tab in a window (and there is another window). Regardless, the previous semantics of `<count>removeTab` was questionable. It was preactically impossible to predict which tabs would removed. This picks the current tab, then those to the right of the current tab, then those to the left.
2016-02-20Remove unused variable.Stephen Blott
2016-02-20Remove (unused) `tabInfoMap`.Stephen Blott
It appears `tabInfoMap` (and related machinery) is not being used. This removes it.
2016-02-20Note moveTabToNewWindow count prefix in README.md.Stephen Blott
2016-02-20Merge pull request #2003 from smblott-github/count-for-new-windowStephen Blott
Make `moveToNewWindow` accept a count.
2016-02-20Merge remote-tracking branch 'upstream/master'Stephen Blott
2016-02-20Note count prefix command options in README.md.Stephen Blott
2016-02-20Merge pull request #2001 from smblott-github/add-count-command-optionStephen Blott
Add count command option