OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 /** | 5 /** |
6 * @constructor | 6 * @constructor |
7 * @extends {WebInspector.SearchResultsPane} | 7 * @extends {WebInspector.SearchResultsPane} |
8 * @param {!WebInspector.ProjectSearchConfig} searchConfig | 8 * @param {!WebInspector.ProjectSearchConfig} searchConfig |
9 */ | 9 */ |
10 WebInspector.FileBasedSearchResultsPane = function(searchConfig) | 10 WebInspector.FileBasedSearchResultsPane = function(searchConfig) |
11 { | 11 { |
12 WebInspector.SearchResultsPane.call(this, searchConfig); | 12 WebInspector.SearchResultsPane.call(this, searchConfig); |
13 | 13 |
14 this._searchResults = []; | 14 this._searchResults = []; |
15 | 15 this._treeOutline = new TreeOutlineInShadow(); |
16 this.element.id = "search-results-pane-file-based"; | 16 this._treeOutline.registerRequiredCSS("sources/fileBasedSearchResultsPane.cs
s"); |
17 this._treeOutline = new TreeOutline(); | |
18 this._treeOutline.element.classList.add("search-results-outline-disclosure")
; | |
19 this.element.appendChild(this._treeOutline.element); | 17 this.element.appendChild(this._treeOutline.element); |
20 | 18 |
21 this._matchesExpandedCount = 0; | 19 this._matchesExpandedCount = 0; |
22 } | 20 } |
23 | 21 |
24 WebInspector.FileBasedSearchResultsPane.matchesExpandedByDefaultCount = 20; | 22 WebInspector.FileBasedSearchResultsPane.matchesExpandedByDefaultCount = 20; |
25 WebInspector.FileBasedSearchResultsPane.fileMatchesShownAtOnce = 20; | 23 WebInspector.FileBasedSearchResultsPane.fileMatchesShownAtOnce = 20; |
26 | 24 |
27 WebInspector.FileBasedSearchResultsPane.prototype = { | 25 WebInspector.FileBasedSearchResultsPane.prototype = { |
28 /** | 26 /** |
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
220 */ | 218 */ |
221 _showMoreMatchesElementSelected: function(startMatchIndex) | 219 _showMoreMatchesElementSelected: function(startMatchIndex) |
222 { | 220 { |
223 this.removeChild(this._showMoreMatchesTreeElement); | 221 this.removeChild(this._showMoreMatchesTreeElement); |
224 this._appendSearchMatches(startMatchIndex, this._searchResult.searchMatc
hes.length); | 222 this._appendSearchMatches(startMatchIndex, this._searchResult.searchMatc
hes.length); |
225 return false; | 223 return false; |
226 }, | 224 }, |
227 | 225 |
228 __proto__: TreeElement.prototype | 226 __proto__: TreeElement.prototype |
229 } | 227 } |
OLD | NEW |