Chromium Code Reviews| Index: third_party/WebKit/Source/devtools/front_end/ui/TextPrompt.js |
| diff --git a/third_party/WebKit/Source/devtools/front_end/ui/TextPrompt.js b/third_party/WebKit/Source/devtools/front_end/ui/TextPrompt.js |
| index 84e2a53008fc318af03a155a6ef02e08109ad043..ff1d62a3e533cfbfc60ccc12c8ae6b01e2ef2473 100644 |
| --- a/third_party/WebKit/Source/devtools/front_end/ui/TextPrompt.js |
| +++ b/third_party/WebKit/Source/devtools/front_end/ui/TextPrompt.js |
| @@ -189,6 +189,22 @@ WebInspector.TextPrompt.prototype = { |
| this._element.scrollIntoView(); |
| }, |
| + /** |
| + * @return {string} |
| + */ |
| + title: function() |
| + { |
| + return this._element.title; |
|
lushnikov
2016/03/25 18:48:32
In order to make methods title() and setTitle() in
|
| + }, |
| + |
| + /** |
| + * @param {string} title |
| + */ |
| + setTitle: function(title) |
| + { |
| + this._element.title = title; |
|
lushnikov
2016/03/25 18:48:32
I think it would be better to use this._proxyEleme
|
| + }, |
| + |
| _removeFromElement: function() |
| { |
| this.clearAutoComplete(true); |
| @@ -203,6 +219,16 @@ WebInspector.TextPrompt.prototype = { |
| this._suggestBox.removeFromElement(); |
| }, |
| + onEditStart: function() |
| + { |
| + // Subclasses can implement. |
| + }, |
| + |
| + onEditDone: function() |
| + { |
| + // Subclasses can implement. |
| + }, |
| + |
| /** |
| * @param {function(!Event)=} blurListener |
| */ |
| @@ -220,6 +246,7 @@ WebInspector.TextPrompt.prototype = { |
| WebInspector.setCurrentFocusElement(this._element); |
| if (!this.text()) |
| this._updateAutoComplete(); |
| + this.onEditStart(); |
| }, |
| _stopEditing: function() |
| @@ -229,6 +256,7 @@ WebInspector.TextPrompt.prototype = { |
| this._element.removeEventListener("blur", this._blurListener, false); |
| this._contentElement.classList.remove("text-prompt-editing"); |
| delete this._isEditing; |
| + this.onEditDone(); |
| }, |
| _removeSuggestionAids: function() |