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

Side by Side Diff: Source/devtools/front_end/resources/FileSystemView.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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 this._directoryTree = new TreeOutline(directoryTreeElement); 43 this._directoryTree = new TreeOutline(directoryTreeElement);
44 this.sidebarElement().appendChild(directoryTreeElement); 44 this.sidebarElement().appendChild(directoryTreeElement);
45 this.sidebarElement().classList.add("outline-disclosure", "sidebar"); 45 this.sidebarElement().classList.add("outline-disclosure", "sidebar");
46 46
47 var rootItem = new WebInspector.FileSystemView.EntryTreeElement(this, fileSy stem.root); 47 var rootItem = new WebInspector.FileSystemView.EntryTreeElement(this, fileSy stem.root);
48 rootItem.expanded = true; 48 rootItem.expanded = true;
49 this._directoryTree.appendChild(rootItem); 49 this._directoryTree.appendChild(rootItem);
50 this._visibleView = null; 50 this._visibleView = null;
51 51
52 this._refreshButton = new WebInspector.StatusBarButton(WebInspector.UIString ("Refresh"), "refresh-storage-status-bar-item"); 52 this._refreshButton = new WebInspector.StatusBarButton(WebInspector.UIString ("Refresh"), "refresh-storage-status-bar-item");
53 this._refreshButton.visible = true; 53 this._refreshButton.setVisible(true);
54 this._refreshButton.addEventListener("click", this._refresh, this); 54 this._refreshButton.addEventListener("click", this._refresh, this);
55 55
56 this._deleteButton = new WebInspector.StatusBarButton(WebInspector.UIString( "Delete"), "delete-storage-status-bar-item"); 56 this._deleteButton = new WebInspector.StatusBarButton(WebInspector.UIString( "Delete"), "delete-storage-status-bar-item");
57 this._deleteButton.visible = true; 57 this._deleteButton.setVisible(true);
58 this._deleteButton.addEventListener("click", this._confirmDelete, this); 58 this._deleteButton.addEventListener("click", this._confirmDelete, this);
59 } 59 }
60 60
61 WebInspector.FileSystemView.prototype = { 61 WebInspector.FileSystemView.prototype = {
62 /** 62 /**
63 * @type {!Array.<!Element>} 63 * @type {!Array.<!Element>}
64 */ 64 */
65 get statusBarItems() 65 get statusBarItems()
66 { 66 {
67 return [this._refreshButton.element, this._deleteButton.element]; 67 return [this._refreshButton.element, this._deleteButton.element];
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
234 }, 234 },
235 235
236 _deletionCompleted: function() 236 _deletionCompleted: function()
237 { 237 {
238 if (this._entry != this._entry.fileSystem.root) 238 if (this._entry != this._entry.fileSystem.root)
239 this.parent.refresh(); 239 this.parent.refresh();
240 }, 240 },
241 241
242 __proto__: TreeElement.prototype 242 __proto__: TreeElement.prototype
243 } 243 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698