aboutsummaryrefslogtreecommitdiffstats
path: root/vimiumFrontend.js
diff options
context:
space:
mode:
authorJez Ng2012-02-26 23:29:34 -0500
committerJez Ng2012-02-26 23:29:34 -0500
commit5a663e6b2ffd5f55e518f89ce693eca0bfed134f (patch)
treef3bc843d5c37a527a2efcfbe74d6929e2502a2d7 /vimiumFrontend.js
parentb8f2d7a134bf1914ee62e21d584bee84984fc088 (diff)
downloadvimium-5a663e6b2ffd5f55e518f89ce693eca0bfed134f.tar.bz2
Don't pass <ESC> to page when quitting insert mode.
Diffstat (limited to 'vimiumFrontend.js')
-rw-r--r--vimiumFrontend.js13
1 files changed, 1 insertions, 12 deletions
diff --git a/vimiumFrontend.js b/vimiumFrontend.js
index 75b792b9..66e96d49 100644
--- a/vimiumFrontend.js
+++ b/vimiumFrontend.js
@@ -101,7 +101,6 @@ var settings = {
frameId = Math.floor(Math.random()*999999999)
var hasModifiersRegex = /^<([amc]-)+.>/;
-var googleRegex = /:\/\/[^/]*google[^/]+/;
/*
* Complete initialization work that sould be done prior to DOMReady.
@@ -484,11 +483,7 @@ function onKeydown(event) {
if (isEditable(event.srcElement))
event.srcElement.blur();
exitInsertMode();
-
- // Added to prevent Google Instant from reclaiming the keystroke and putting us back into the search
- // box.
- if (isGoogleSearch())
- event.stopPropagation();
+ suppressEvent(event);
}
}
else if (findMode) {
@@ -557,12 +552,6 @@ function checkIfEnabledForUrl() {
});
}
-// TODO(ilya): This just checks if "google" is in the domain name. Probably should be more targeted.
-function isGoogleSearch() {
- var url = window.location.toString();
- return !!url.match(googleRegex);
-}
-
function refreshCompletionKeys(response) {
if (response) {
currentCompletionKeys = response.completionKeys;