diff options
| author | Phil Crosby | 2012-06-17 00:15:12 -0700 |
|---|---|---|
| committer | Phil Crosby | 2012-06-17 00:15:24 -0700 |
| commit | 5de493d0740835e0d7dbd0e90bcc679df835547f (patch) | |
| tree | 246e5f622ede9b68ba0470be54f7e24a4213f7cc /background_scripts/completion.coffee | |
| parent | c7a4dbbda25c732844543397e4552570ecc0332d (diff) | |
| download | vimium-5de493d0740835e0d7dbd0e90bcc679df835547f.tar.bz2 | |
Use the browser's built-in bind() instead of our proxy()
Diffstat (limited to 'background_scripts/completion.coffee')
| -rw-r--r-- | background_scripts/completion.coffee | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/background_scripts/completion.coffee b/background_scripts/completion.coffee index 5d0f939a..b9069dce 100644 --- a/background_scripts/completion.coffee +++ b/background_scripts/completion.coffee @@ -174,7 +174,7 @@ class DomainCompleter if domain previousEntry = @domains[domain] @domains[domain] = entry if !previousEntry || (previousEntry.lastVisitTime < entry.lastVisitTime) - chrome.history.onVisited.addListener(@onPageVisited.proxy(this)) + chrome.history.onVisited.addListener(@onPageVisited.bind(this)) onComplete() onPageVisited: (newPage) -> @@ -320,7 +320,7 @@ HistoryCache = chrome.history.search { text: "", maxResults: @size, startTime: 0 }, (history) => history.sort @compareHistoryByUrl @history = history - chrome.history.onVisited.addListener(@onPageVisited.proxy(this)) + chrome.history.onVisited.addListener(@onPageVisited.bind(this)) callback(@history) for callback in @callbacks @callbacks = null |
