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

Unified Diff: Source/devtools/front_end/resources/CookieItemsView.js

Issue 722713002: DevTools: get rid of getters and setters in StatusBarButton. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 1 month 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: Source/devtools/front_end/resources/CookieItemsView.js
diff --git a/Source/devtools/front_end/resources/CookieItemsView.js b/Source/devtools/front_end/resources/CookieItemsView.js
index 8cfdcfd9e5e15a4b7457177e62c85dd243dd7c5b..b48b20b1b0ff660f2629dcb7261d8aee51ca5bb2 100644
--- a/Source/devtools/front_end/resources/CookieItemsView.js
+++ b/Source/devtools/front_end/resources/CookieItemsView.js
@@ -38,11 +38,11 @@ WebInspector.CookieItemsView = function(treeElement, cookieDomain)
this.element.classList.add("storage-view");
this._deleteButton = new WebInspector.StatusBarButton(WebInspector.UIString("Delete"), "delete-storage-status-bar-item");
- this._deleteButton.visible = false;
+ this._deleteButton.setVisible(false);
this._deleteButton.addEventListener("click", this._deleteButtonClicked, this);
this._clearButton = new WebInspector.StatusBarButton(WebInspector.UIString("Clear"), "clear-storage-status-bar-item");
- this._clearButton.visible = false;
+ this._clearButton.setVisible(false);
this._clearButton.addEventListener("click", this._clearButtonClicked, this);
this._refreshButton = new WebInspector.StatusBarButton(WebInspector.UIString("Refresh"), "refresh-storage-status-bar-item");
@@ -70,7 +70,7 @@ WebInspector.CookieItemsView.prototype = {
willHide: function()
{
- this._deleteButton.visible = false;
+ this._deleteButton.setVisible(false);
},
_update: function()
@@ -88,8 +88,8 @@ WebInspector.CookieItemsView.prototype = {
if (!this._cookies.length) {
// Nothing to show.
this._emptyView.show(this.element);
- this._clearButton.visible = false;
- this._deleteButton.visible = false;
+ this._clearButton.setVisible(false);
+ this._deleteButton.setVisible(false);
if (this._cookiesTable)
this._cookiesTable.detach();
return;
@@ -103,8 +103,8 @@ WebInspector.CookieItemsView.prototype = {
this._cookiesTable.show(this.element);
this._treeElement.subtitle = String.sprintf(WebInspector.UIString("%d cookies (%s)"), this._cookies.length,
Number.bytesToString(this._totalSize));
- this._clearButton.visible = true;
- this._deleteButton.visible = !!this._cookiesTable.selectedCookie();
+ this._clearButton.setVisible(true);
+ this._deleteButton.setVisible(!!this._cookiesTable.selectedCookie());
},
/**
@@ -157,7 +157,7 @@ WebInspector.CookieItemsView.prototype = {
_showDeleteButton: function()
{
- this._deleteButton.visible = true;
+ this._deleteButton.setVisible(true);
},
_deleteButtonClicked: function()

Powered by Google App Engine
This is Rietveld 408576698