mirror of
https://github.com/huhu/rust-search-extension
synced 2024-11-13 23:27:13 +00:00
Rename onSelected() to afterNavigated()
This commit is contained in:
parent
28f7b0b538
commit
a7913dceb9
2 changed files with 4 additions and 4 deletions
|
@ -36,7 +36,7 @@ omnibox.bootstrap({
|
|||
return content;
|
||||
}
|
||||
},
|
||||
onSelected: (query, result) => {
|
||||
afterNavigated: (query, result) => {
|
||||
HistoryCommand.record(query, result);
|
||||
}
|
||||
});
|
||||
|
|
|
@ -43,7 +43,7 @@ Omnibox.prototype.parse = function(input) {
|
|||
return {query: query.join(" "), page};
|
||||
};
|
||||
|
||||
Omnibox.prototype.bootstrap = function({onSearch, onFormat, onAppend, beforeNavigate, onSelected}) {
|
||||
Omnibox.prototype.bootstrap = function({onSearch, onFormat, onAppend, beforeNavigate, afterNavigated}) {
|
||||
this.globalEvent = new QueryEvent({onSearch, onFormat, onAppend});
|
||||
this.setDefaultSuggestion(this.defaultSuggestionDescription);
|
||||
let results;
|
||||
|
@ -94,8 +94,8 @@ Omnibox.prototype.bootstrap = function({onSearch, onFormat, onAppend, beforeNavi
|
|||
}
|
||||
}
|
||||
|
||||
if (onSelected) {
|
||||
onSelected(this.cachedQuery, result);
|
||||
if (afterNavigated) {
|
||||
afterNavigated(this.cachedQuery, result);
|
||||
}
|
||||
|
||||
this.setDefaultSuggestion(this.defaultSuggestionDescription);
|
||||
|
|
Loading…
Reference in a new issue