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

Unified Diff: cc/resources/prioritized_resource.cc

Issue 638353002: [C++11 Allowed Features] Declares a type-safe null pointer converting from NULL to nullptr in src/… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Formating. Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
Index: cc/resources/prioritized_resource.cc
diff --git a/cc/resources/prioritized_resource.cc b/cc/resources/prioritized_resource.cc
index 462f7f1bb0c6cf19ca8fdac7705f9e739760da07..54d0dbdad1f9e3b152d8a680f129daba710fa991 100644
--- a/cc/resources/prioritized_resource.cc
+++ b/cc/resources/prioritized_resource.cc
@@ -23,8 +23,8 @@ PrioritizedResource::PrioritizedResource(PrioritizedResourceManager* manager,
priority_(PriorityCalculator::LowestPriority()),
is_above_priority_cutoff_(false),
is_self_managed_(false),
- backing_(NULL),
- manager_(NULL) {
+ backing_(nullptr),
+ manager_(nullptr) {
bytes_ = Resource::MemorySizeBytes(size, format);
if (manager)
manager->RegisterTexture(this);
@@ -106,8 +106,8 @@ void PrioritizedResource::Unlink() {
DCHECK(backing_);
DCHECK(backing_->owner_ == this);
- backing_->owner_ = NULL;
- backing_ = NULL;
+ backing_->owner_ = nullptr;
+ backing_ = nullptr;
}
void PrioritizedResource::SetToSelfManagedMemoryPlaceholder(size_t bytes) {
@@ -121,7 +121,7 @@ PrioritizedResource::Backing::Backing(unsigned id,
const gfx::Size& size,
ResourceFormat format)
: Resource(id, size, format),
- owner_(NULL),
+ owner_(nullptr),
priority_at_last_priority_update_(PriorityCalculator::LowestPriority()),
was_above_priority_cutoff_at_last_priority_update_(false),
in_drawing_impl_tree_(false),
@@ -196,7 +196,7 @@ void PrioritizedResource::ReturnBackingTexture() {
const Proxy* PrioritizedResource::Backing::proxy() const {
if (!owner_ || !owner_->resource_manager())
- return NULL;
+ return nullptr;
return owner_->resource_manager()->ProxyForDebug();
}

Powered by Google App Engine
This is Rietveld 408576698