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

Side by Side Diff: content/browser/indexed_db/indexed_db_internals_ui.cc

Issue 312093005: IndexedDB: Sprinkle DISALLOW_COPY_AND_ASSIGN where appropriate (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Whitespace fixes Created 6 years, 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/browser/indexed_db/indexed_db_internals_ui.h" 5 #include "content/browser/indexed_db/indexed_db_internals_ui.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/files/scoped_temp_dir.h" 10 #include "base/files/scoped_temp_dir.h"
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
303 explicit FileDeleter(const base::FilePath& temp_dir) : temp_dir_(temp_dir) {} 303 explicit FileDeleter(const base::FilePath& temp_dir) : temp_dir_(temp_dir) {}
304 virtual ~FileDeleter(); 304 virtual ~FileDeleter();
305 305
306 virtual void OnDownloadUpdated(DownloadItem* download) OVERRIDE; 306 virtual void OnDownloadUpdated(DownloadItem* download) OVERRIDE;
307 virtual void OnDownloadOpened(DownloadItem* item) OVERRIDE {} 307 virtual void OnDownloadOpened(DownloadItem* item) OVERRIDE {}
308 virtual void OnDownloadRemoved(DownloadItem* item) OVERRIDE {} 308 virtual void OnDownloadRemoved(DownloadItem* item) OVERRIDE {}
309 virtual void OnDownloadDestroyed(DownloadItem* item) OVERRIDE {} 309 virtual void OnDownloadDestroyed(DownloadItem* item) OVERRIDE {}
310 310
311 private: 311 private:
312 const base::FilePath temp_dir_; 312 const base::FilePath temp_dir_;
313
314 DISALLOW_COPY_AND_ASSIGN(FileDeleter);
313 }; 315 };
314 316
315 void FileDeleter::OnDownloadUpdated(DownloadItem* item) { 317 void FileDeleter::OnDownloadUpdated(DownloadItem* item) {
316 switch (item->GetState()) { 318 switch (item->GetState()) {
317 case DownloadItem::IN_PROGRESS: 319 case DownloadItem::IN_PROGRESS:
318 break; 320 break;
319 case DownloadItem::COMPLETE: 321 case DownloadItem::COMPLETE:
320 case DownloadItem::CANCELLED: 322 case DownloadItem::CANCELLED:
321 case DownloadItem::INTERRUPTED: { 323 case DownloadItem::INTERRUPTED: {
322 item->RemoveObserver(this); 324 item->RemoveObserver(this);
(...skipping 27 matching lines...) Expand all
350 352
351 item->AddObserver(new FileDeleter(temp_path)); 353 item->AddObserver(new FileDeleter(temp_path));
352 web_ui()->CallJavascriptFunction( 354 web_ui()->CallJavascriptFunction(
353 "indexeddb.onOriginDownloadReady", 355 "indexeddb.onOriginDownloadReady",
354 base::StringValue(partition_path.value()), 356 base::StringValue(partition_path.value()),
355 base::StringValue(origin_url.spec()), 357 base::StringValue(origin_url.spec()),
356 base::FundamentalValue(double(connection_count))); 358 base::FundamentalValue(double(connection_count)));
357 } 359 }
358 360
359 } // namespace content 361 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698