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

Unified Diff: third_party/WebKit/Source/devtools/front_end/sources/WatchExpressionsSidebarPane.js

Issue 2217783002: DevTools: use view locations in the elements and sources sidebars. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: for landing Created 4 years, 4 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
Index: third_party/WebKit/Source/devtools/front_end/sources/WatchExpressionsSidebarPane.js
diff --git a/third_party/WebKit/Source/devtools/front_end/sources/WatchExpressionsSidebarPane.js b/third_party/WebKit/Source/devtools/front_end/sources/WatchExpressionsSidebarPane.js
index 54ef09fb55f406912d4aa78330363c77411bfa0d..bbcdf0febb10ae51e308f31b0d1160ad4968ba2f 100644
--- a/third_party/WebKit/Source/devtools/front_end/sources/WatchExpressionsSidebarPane.js
+++ b/third_party/WebKit/Source/devtools/front_end/sources/WatchExpressionsSidebarPane.js
@@ -30,11 +30,11 @@
/**
* @constructor
- * @extends {WebInspector.View}
+ * @extends {WebInspector.SimpleView}
*/
WebInspector.WatchExpressionsSidebarPane = function()
{
- WebInspector.View.call(this, WebInspector.UIString("Watch"));
+ WebInspector.SimpleView.call(this, WebInspector.UIString("Watch"));
this.registerRequiredCSS("components/objectValue.css");
this._requiresUpdate = true;
@@ -75,7 +75,7 @@ WebInspector.WatchExpressionsSidebarPane.prototype = {
*/
addExpression: function(expressionString)
{
- this.revealWidget();
+ this.revealView();
if (this._requiresUpdate) {
this._rebuildWatchExpressions();
delete this._requiresUpdate;
@@ -84,10 +84,12 @@ WebInspector.WatchExpressionsSidebarPane.prototype = {
this._saveExpressions();
},
- expandIfNecessary: function()
+ /**
+ * @return {boolean}
+ */
+ hasExpressions: function()
{
- if (this._watchExpressionsSetting.get().length)
- this.revealWidget();
+ return !!this._watchExpressionsSetting.get().length;
},
_saveExpressions: function()
@@ -116,7 +118,7 @@ WebInspector.WatchExpressionsSidebarPane.prototype = {
{
if (event)
event.consume(true);
- this.revealWidget();
+ this.revealView();
this._createWatchExpression(null).startEditing();
},
@@ -213,7 +215,7 @@ WebInspector.WatchExpressionsSidebarPane.prototype = {
this._rebuildWatchExpressions();
},
- __proto__: WebInspector.View.prototype
+ __proto__: WebInspector.SimpleView.prototype
}
/**

Powered by Google App Engine
This is Rietveld 408576698