This commit is contained in:
Tim Taubert 2013-04-30 10:39:24 +02:00
Родитель 4d4ba8caf7 bd818d0778
Коммит 7e366b69e4
3 изменённых файлов: 17 добавлений и 3 удалений

4
.gitignore поставляемый
Просмотреть файл

@ -51,3 +51,7 @@ parser/html/java/javaparser/
python/psutil/*.so
python/psutil/*.pyd
python/psutil/build/
# Ignore chrome.manifest files from the devtools loader
browser/devtools/chrome.manifest
toolkit/devtools/chrome.manifest

Просмотреть файл

@ -54,3 +54,7 @@ _OPT\.OBJ/
# Git repositories
.git/
# Ignore chrome.manifest files from the devtools loader
^browser/devtools/chrome.manifest$
^toolkit/devtools/chrome.manifest$

Просмотреть файл

@ -184,6 +184,14 @@ InspectorPanel.prototype = {
* Hooks the searchbar to show result and auto completion suggestions.
*/
setupSearchBox: function InspectorPanel_setupSearchBox() {
let searchDoc;
if (this.target.isLocalTab) {
searchDoc = this.browser.contentDocument;
} else if (this.target.window) {
searchDoc = this.target.window.document;
} else {
return;
}
// Initiate the selectors search object.
let setNodeFunction = function(node) {
this.selection.setNode(node, "selectorsearch");
@ -193,9 +201,7 @@ InspectorPanel.prototype = {
this.searchSuggestions = null;
}
this.searchBox = this.panelDoc.getElementById("inspector-searchbox");
this.searchSuggestions = new SelectorSearch(this.browser.contentDocument,
this.searchBox,
setNodeFunction);
this.searchSuggestions = new SelectorSearch(searchDoc, this.searchBox, setNodeFunction);
},
/**