| Index: Source/devtools/front_end/console/ConsoleViewMessage.js
|
| diff --git a/Source/devtools/front_end/console/ConsoleViewMessage.js b/Source/devtools/front_end/console/ConsoleViewMessage.js
|
| index 2b79ff628cc2d5f5ebdb7a518e722ac50cc75ad3..810dffd8d3653e320f22264776919fde3aa762a3 100644
|
| --- a/Source/devtools/front_end/console/ConsoleViewMessage.js
|
| +++ b/Source/devtools/front_end/console/ConsoleViewMessage.js
|
| @@ -958,22 +958,12 @@ WebInspector.ConsoleViewMessage.prototype = {
|
| return String.format(format, parameters, formatters, formattedResult, append);
|
| },
|
|
|
| - clearHighlight: function()
|
| + clearHighlights: function()
|
| {
|
| if (!this._formattedMessage)
|
| return;
|
|
|
| - WebInspector.removeSearchResultsHighlight(this._formattedMessage);
|
| - },
|
| -
|
| - highlightSearchResults: function(regexObject)
|
| - {
|
| - if (!this._formattedMessage)
|
| - return;
|
| -
|
| - this._highlightSearchResultsInElement(regexObject, this._messageElement);
|
| - if (this._anchorElement)
|
| - this._highlightSearchResultsInElement(regexObject, this._anchorElement);
|
| + WebInspector.removeSearchResultsHighlight(this._formattedMessage, WebInspector.highlightedSearchResultClassName);
|
| },
|
|
|
| _highlightSearchResultsInElement: function(regexObject, element)
|
| @@ -1290,6 +1280,28 @@ WebInspector.ConsoleViewMessage.prototype = {
|
| },
|
|
|
| /**
|
| + * @return {string}
|
| + */
|
| + renderedText: function ()
|
| + {
|
| + if (!this._messageElement)
|
| + return "";
|
| + return this._messageElement.textContent;
|
| + },
|
| +
|
| + /**
|
| + * @param {!Array.<!Object>} ranges
|
| + * @return {!Array.<!Element>}
|
| + */
|
| + highlightMatches: function(ranges)
|
| + {
|
| + var highlightNodes = [];
|
| + if (this._formattedMessage)
|
| + highlightNodes = WebInspector.highlightSearchResults(this._messageElement, ranges);
|
| + return highlightNodes;
|
| + },
|
| +
|
| + /**
|
| * @param {string} string
|
| * @return {?Element}
|
| */
|
|
|