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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/resources/IndexedDBViews.js

Issue 2440953003: DevTools: use semicolons after each statement. (Closed)
Patch Set: rebaseline Created 4 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
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 28 matching lines...) Expand all
39 this.registerRequiredCSS("resources/indexedDBViews.css"); 39 this.registerRequiredCSS("resources/indexedDBViews.css");
40 40
41 this.element.classList.add("indexed-db-database-view"); 41 this.element.classList.add("indexed-db-database-view");
42 this.element.classList.add("storage-view"); 42 this.element.classList.add("storage-view");
43 43
44 this._securityOriginElement = this.element.createChild("div", "header-row"); 44 this._securityOriginElement = this.element.createChild("div", "header-row");
45 this._nameElement = this.element.createChild("div", "header-row"); 45 this._nameElement = this.element.createChild("div", "header-row");
46 this._versionElement = this.element.createChild("div", "header-row"); 46 this._versionElement = this.element.createChild("div", "header-row");
47 47
48 this.update(database); 48 this.update(database);
49 } 49 };
50 50
51 WebInspector.IDBDatabaseView.prototype = { 51 WebInspector.IDBDatabaseView.prototype = {
52 /** 52 /**
53 * @param {!Element} element 53 * @param {!Element} element
54 * @param {string} name 54 * @param {string} name
55 * @param {string} value 55 * @param {string} value
56 */ 56 */
57 _formatHeader: function(element, name, value) 57 _formatHeader: function(element, name, value)
58 { 58 {
59 element.removeChildren(); 59 element.removeChildren();
(...skipping 11 matching lines...) Expand all
71 /** 71 /**
72 * @param {!WebInspector.IndexedDBModel.Database} database 72 * @param {!WebInspector.IndexedDBModel.Database} database
73 */ 73 */
74 update: function(database) 74 update: function(database)
75 { 75 {
76 this._database = database; 76 this._database = database;
77 this._refreshDatabase(); 77 this._refreshDatabase();
78 }, 78 },
79 79
80 __proto__: WebInspector.VBox.prototype 80 __proto__: WebInspector.VBox.prototype
81 } 81 };
82 82
83 83
84 /** 84 /**
85 * @constructor 85 * @constructor
86 * @extends {WebInspector.SimpleView} 86 * @extends {WebInspector.SimpleView}
87 * @param {!WebInspector.IndexedDBModel} model 87 * @param {!WebInspector.IndexedDBModel} model
88 * @param {!WebInspector.IndexedDBModel.DatabaseId} databaseId 88 * @param {!WebInspector.IndexedDBModel.DatabaseId} databaseId
89 * @param {!WebInspector.IndexedDBModel.ObjectStore} objectStore 89 * @param {!WebInspector.IndexedDBModel.ObjectStore} objectStore
90 * @param {?WebInspector.IndexedDBModel.Index} index 90 * @param {?WebInspector.IndexedDBModel.Index} index
91 */ 91 */
(...skipping 14 matching lines...) Expand all
106 this._refreshButton.addEventListener("click", this._refreshButtonClicked, th is); 106 this._refreshButton.addEventListener("click", this._refreshButtonClicked, th is);
107 107
108 this._clearButton = new WebInspector.ToolbarButton(WebInspector.UIString("Cl ear object store"), "clear-toolbar-item"); 108 this._clearButton = new WebInspector.ToolbarButton(WebInspector.UIString("Cl ear object store"), "clear-toolbar-item");
109 this._clearButton.addEventListener("click", this._clearButtonClicked, this); 109 this._clearButton.addEventListener("click", this._clearButtonClicked, this);
110 110
111 this._pageSize = 50; 111 this._pageSize = 50;
112 this._skipCount = 0; 112 this._skipCount = 0;
113 113
114 this.update(objectStore, index); 114 this.update(objectStore, index);
115 this._entries = []; 115 this._entries = [];
116 } 116 };
117 117
118 WebInspector.IDBDataView.prototype = { 118 WebInspector.IDBDataView.prototype = {
119 /** 119 /**
120 * @return {!WebInspector.DataGrid} 120 * @return {!WebInspector.DataGrid}
121 */ 121 */
122 _createDataGrid: function() 122 _createDataGrid: function()
123 { 123 {
124 var keyPath = this._isIndex ? this._index.keyPath : this._objectStore.ke yPath; 124 var keyPath = this._isIndex ? this._index.keyPath : this._objectStore.ke yPath;
125 125
126 var columns = []; 126 var columns = [];
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after
328 return [this._refreshButton, this._clearButton]; 328 return [this._refreshButton, this._clearButton];
329 }, 329 },
330 330
331 clear: function() 331 clear: function()
332 { 332 {
333 this._dataGrid.rootNode().removeChildren(); 333 this._dataGrid.rootNode().removeChildren();
334 this._entries = []; 334 this._entries = [];
335 }, 335 },
336 336
337 __proto__: WebInspector.SimpleView.prototype 337 __proto__: WebInspector.SimpleView.prototype
338 } 338 };
339 339
340 /** 340 /**
341 * @constructor 341 * @constructor
342 * @extends {WebInspector.DataGridNode} 342 * @extends {WebInspector.DataGridNode}
343 * @param {!Object.<string, *>} data 343 * @param {!Object.<string, *>} data
344 */ 344 */
345 WebInspector.IDBDataGridNode = function(data) 345 WebInspector.IDBDataGridNode = function(data)
346 { 346 {
347 WebInspector.DataGridNode.call(this, data, false); 347 WebInspector.DataGridNode.call(this, data, false);
348 this.selectable = false; 348 this.selectable = false;
349 } 349 };
350 350
351 WebInspector.IDBDataGridNode.prototype = { 351 WebInspector.IDBDataGridNode.prototype = {
352 /** 352 /**
353 * @override 353 * @override
354 * @return {!Element} 354 * @return {!Element}
355 */ 355 */
356 createCell: function(columnIdentifier) 356 createCell: function(columnIdentifier)
357 { 357 {
358 var cell = WebInspector.DataGridNode.prototype.createCell.call(this, col umnIdentifier); 358 var cell = WebInspector.DataGridNode.prototype.createCell.call(this, col umnIdentifier);
359 var value = this.data[columnIdentifier]; 359 var value = this.data[columnIdentifier];
360 360
361 switch (columnIdentifier) { 361 switch (columnIdentifier) {
362 case "value": 362 case "value":
363 case "key": 363 case "key":
364 case "primaryKey": 364 case "primaryKey":
365 cell.removeChildren(); 365 cell.removeChildren();
366 var objectElement = WebInspector.ObjectPropertiesSection.defaultObje ctPresentation(value, undefined, true); 366 var objectElement = WebInspector.ObjectPropertiesSection.defaultObje ctPresentation(value, undefined, true);
367 cell.appendChild(objectElement); 367 cell.appendChild(objectElement);
368 break; 368 break;
369 default: 369 default:
370 } 370 }
371 371
372 return cell; 372 return cell;
373 }, 373 },
374 374
375 __proto__: WebInspector.DataGridNode.prototype 375 __proto__: WebInspector.DataGridNode.prototype
376 } 376 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698