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

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

Issue 2632553002: [DevTools] Clear local storage (Closed)
Patch Set: [DevTools] Clear local storage Created 3 years, 11 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Nokia Inc. All rights reserved. 2 * Copyright (C) 2008 Nokia Inc. All rights reserved.
3 * Copyright (C) 2013 Samsung Electronics. All rights reserved. 3 * Copyright (C) 2013 Samsung Electronics. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 setItem(key, value) { 81 setItem(key, value) {
82 this._model._agent.setDOMStorageItem(this.id, key, value); 82 this._model._agent.setDOMStorageItem(this.id, key, value);
83 } 83 }
84 84
85 /** 85 /**
86 * @param {string} key 86 * @param {string} key
87 */ 87 */
88 removeItem(key) { 88 removeItem(key) {
89 this._model._agent.removeDOMStorageItem(this.id, key); 89 this._model._agent.removeDOMStorageItem(this.id, key);
90 } 90 }
91
92 clear() {
93 this._model._agent.clear(this.id);
94 }
91 }; 95 };
92 96
93 97
94 /** @enum {symbol} */ 98 /** @enum {symbol} */
95 Resources.DOMStorage.Events = { 99 Resources.DOMStorage.Events = {
96 DOMStorageItemsCleared: Symbol('DOMStorageItemsCleared'), 100 DOMStorageItemsCleared: Symbol('DOMStorageItemsCleared'),
97 DOMStorageItemRemoved: Symbol('DOMStorageItemRemoved'), 101 DOMStorageItemRemoved: Symbol('DOMStorageItemRemoved'),
98 DOMStorageItemAdded: Symbol('DOMStorageItemAdded'), 102 DOMStorageItemAdded: Symbol('DOMStorageItemAdded'),
99 DOMStorageItemUpdated: Symbol('DOMStorageItemUpdated') 103 DOMStorageItemUpdated: Symbol('DOMStorageItemUpdated')
100 }; 104 };
(...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 * @param {string} key 340 * @param {string} key
337 * @param {string} oldValue 341 * @param {string} oldValue
338 * @param {string} value 342 * @param {string} value
339 */ 343 */
340 domStorageItemUpdated(storageId, key, oldValue, value) { 344 domStorageItemUpdated(storageId, key, oldValue, value) {
341 this._model._domStorageItemUpdated(storageId, key, oldValue, value); 345 this._model._domStorageItemUpdated(storageId, key, oldValue, value);
342 } 346 }
343 }; 347 };
344 348
345 Resources.DOMStorageModel._symbol = Symbol('DomStorage'); 349 Resources.DOMStorageModel._symbol = Symbol('DomStorage');
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698