Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(194)

Unified Diff: Source/devtools/front_end/ui/TextPrompt.js

Issue 663083007: [DevTools] Hide suggestion in TextPrompt on window resize. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/devtools/front_end/ui/TextPrompt.js
diff --git a/Source/devtools/front_end/ui/TextPrompt.js b/Source/devtools/front_end/ui/TextPrompt.js
index 0e63e8312e1012938ed0d199cb541c07146f490b..a5d99f82b4f3e806c13ff927e934209424eeb327 100644
--- a/Source/devtools/front_end/ui/TextPrompt.js
+++ b/Source/devtools/front_end/ui/TextPrompt.js
@@ -134,6 +134,7 @@ WebInspector.TextPrompt.prototype = {
this._element.addEventListener("mousewheel", this._boundOnMouseWheel, false);
this._element.addEventListener("selectstart", this._boundSelectStart, false);
this._element.addEventListener("blur", this._boundRemoveSuggestionAids, false);
+ this._element.ownerDocument.defaultView.addEventListener("resize", this._boundRemoveSuggestionAids, false);
if (this._suggestBoxEnabled)
this._suggestBox = new WebInspector.SuggestBox(this);
@@ -184,6 +185,7 @@ WebInspector.TextPrompt.prototype = {
this._element.removeEventListener("input", this._boundOnInput, false);
this._element.removeEventListener("selectstart", this._boundSelectStart, false);
this._element.removeEventListener("blur", this._boundRemoveSuggestionAids, false);
+ this._element.ownerDocument.defaultView.removeEventListener("resize", this._boundRemoveSuggestionAids, false);
if (this._isEditing)
this._stopEditing();
if (this._suggestBox)
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698