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

Side by Side Diff: athena/extensions/extensions_delegate.cc

Issue 653563004: NULL -> nullptr under athena/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "athena/extensions/public/extensions_delegate.h" 5 #include "athena/extensions/public/extensions_delegate.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 8
9 namespace athena { 9 namespace athena {
10 namespace { 10 namespace {
11 11
12 ExtensionsDelegate* instance = NULL; 12 ExtensionsDelegate* instance = nullptr;
13 13
14 } // namespace 14 } // namespace
15 15
16 ExtensionsDelegate::ExtensionsDelegate() { 16 ExtensionsDelegate::ExtensionsDelegate() {
17 DCHECK(!instance); 17 DCHECK(!instance);
18 instance = this; 18 instance = this;
19 } 19 }
20 20
21 ExtensionsDelegate::~ExtensionsDelegate() { 21 ExtensionsDelegate::~ExtensionsDelegate() {
22 DCHECK(instance); 22 DCHECK(instance);
23 instance = NULL; 23 instance = nullptr;
24 } 24 }
25 25
26 // static 26 // static
27 ExtensionsDelegate* ExtensionsDelegate::Get(content::BrowserContext* context) { 27 ExtensionsDelegate* ExtensionsDelegate::Get(content::BrowserContext* context) {
28 DCHECK(instance); 28 DCHECK(instance);
29 DCHECK_EQ(context, instance->GetBrowserContext()); 29 DCHECK_EQ(context, instance->GetBrowserContext());
30 return instance; 30 return instance;
31 } 31 }
32 32
33 // static 33 // static
34 void ExtensionsDelegate::Shutdown() { 34 void ExtensionsDelegate::Shutdown() {
35 DCHECK(instance); 35 DCHECK(instance);
36 delete instance; 36 delete instance;
37 } 37 }
38 38
39 } // namespace athena 39 } // namespace athena
OLDNEW
« no previous file with comments | « athena/extensions/extension_app_model_builder.cc ('k') | athena/extensions/shell/athena_shell_app_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698