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

Side by Side Diff: webkit/fileapi/local_file_system_operation.cc

Issue 14307012: webkit: Remove use of ALLOW_THIS_IN_INITIALIZER_LIST. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 7 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "webkit/fileapi/local_file_system_operation.h" 5 #include "webkit/fileapi/local_file_system_operation.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/single_thread_task_runner.h" 8 #include "base/single_thread_task_runner.h"
9 #include "base/time.h" 9 #include "base/time.h"
10 #include "base/utf_string_conversions.h" 10 #include "base/utf_string_conversions.h"
(...skipping 23 matching lines...) Expand all
34 namespace fileapi { 34 namespace fileapi {
35 35
36 LocalFileSystemOperation::LocalFileSystemOperation( 36 LocalFileSystemOperation::LocalFileSystemOperation(
37 FileSystemContext* file_system_context, 37 FileSystemContext* file_system_context,
38 scoped_ptr<FileSystemOperationContext> operation_context) 38 scoped_ptr<FileSystemOperationContext> operation_context)
39 : file_system_context_(file_system_context), 39 : file_system_context_(file_system_context),
40 operation_context_(operation_context.Pass()), 40 operation_context_(operation_context.Pass()),
41 async_file_util_(NULL), 41 async_file_util_(NULL),
42 peer_handle_(base::kNullProcessHandle), 42 peer_handle_(base::kNullProcessHandle),
43 pending_operation_(kOperationNone), 43 pending_operation_(kOperationNone),
44 weak_factory_(ALLOW_THIS_IN_INITIALIZER_LIST(this)) { 44 weak_factory_(this) {
45 DCHECK(operation_context_.get()); 45 DCHECK(operation_context_.get());
46 operation_context_->DetachUserDataThread(); 46 operation_context_->DetachUserDataThread();
47 } 47 }
48 48
49 LocalFileSystemOperation::~LocalFileSystemOperation() { 49 LocalFileSystemOperation::~LocalFileSystemOperation() {
50 if (!operation_context()) 50 if (!operation_context())
51 return; 51 return;
52 operation_context()->DetachUserDataThread(); 52 operation_context()->DetachUserDataThread();
53 if (write_target_url_.is_valid()) { 53 if (write_target_url_.is_valid()) {
54 operation_context()->update_observers()->Notify( 54 operation_context()->update_observers()->Notify(
(...skipping 813 matching lines...) Expand 10 before | Expand all | Expand 10 after
868 } 868 }
869 869
870 bool LocalFileSystemOperation::SetPendingOperationType(OperationType type) { 870 bool LocalFileSystemOperation::SetPendingOperationType(OperationType type) {
871 if (pending_operation_ != kOperationNone) 871 if (pending_operation_ != kOperationNone)
872 return false; 872 return false;
873 pending_operation_ = type; 873 pending_operation_ = type;
874 return true; 874 return true;
875 } 875 }
876 876
877 } // namespace fileapi 877 } // namespace fileapi
OLDNEW
« no previous file with comments | « webkit/fileapi/local_file_stream_writer.cc ('k') | webkit/fileapi/local_file_system_quota_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698