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

Side by Side Diff: webkit/dom_storage/dom_storage_area.cc

Issue 16155009: Update webkit/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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) 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/dom_storage/dom_storage_area.h" 5 #include "webkit/dom_storage/dom_storage_area.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 commit_batch->changed_values.clear(); 194 commit_batch->changed_values.clear();
195 } 195 }
196 } 196 }
197 197
198 DomStorageArea* DomStorageArea::ShallowCopy( 198 DomStorageArea* DomStorageArea::ShallowCopy(
199 int64 destination_namespace_id, 199 int64 destination_namespace_id,
200 const std::string& destination_persistent_namespace_id) { 200 const std::string& destination_persistent_namespace_id) {
201 DCHECK_NE(kLocalStorageNamespaceId, namespace_id_); 201 DCHECK_NE(kLocalStorageNamespaceId, namespace_id_);
202 DCHECK_NE(kLocalStorageNamespaceId, destination_namespace_id); 202 DCHECK_NE(kLocalStorageNamespaceId, destination_namespace_id);
203 203
204 DomStorageArea* copy = new DomStorageArea( 204 DomStorageArea* copy = new DomStorageArea(destination_namespace_id,
205 destination_namespace_id, destination_persistent_namespace_id, origin_, 205 destination_persistent_namespace_id,
206 session_storage_backing_, task_runner_); 206 origin_,
207 session_storage_backing_.get(),
208 task_runner_.get());
207 copy->map_ = map_; 209 copy->map_ = map_;
208 copy->is_shutdown_ = is_shutdown_; 210 copy->is_shutdown_ = is_shutdown_;
209 copy->is_initial_import_done_ = true; 211 copy->is_initial_import_done_ = true;
210 212
211 // All the uncommitted changes to this area need to happen before the actual 213 // All the uncommitted changes to this area need to happen before the actual
212 // shallow copy is made (scheduled by the upper layer). Another OnCommitTimer 214 // shallow copy is made (scheduled by the upper layer). Another OnCommitTimer
213 // call might be in the event queue at this point, but it's handled gracefully 215 // call might be in the event queue at this point, but it's handled gracefully
214 // when it fires. 216 // when it fires.
215 if (commit_batch_) 217 if (commit_batch_)
216 OnCommitTimer(); 218 OnCommitTimer();
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after
389 commit_batch_->clear_all_first, 391 commit_batch_->clear_all_first,
390 commit_batch_->changed_values); 392 commit_batch_->changed_values);
391 DCHECK(success); 393 DCHECK(success);
392 } 394 }
393 commit_batch_.reset(); 395 commit_batch_.reset();
394 backing_.reset(); 396 backing_.reset();
395 session_storage_backing_ = NULL; 397 session_storage_backing_ = NULL;
396 } 398 }
397 399
398 } // namespace dom_storage 400 } // namespace dom_storage
OLDNEW
« no previous file with comments | « webkit/common/gpu/webgraphicscontext3d_in_process_impl.cc ('k') | webkit/dom_storage/dom_storage_cached_area.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698