| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "chrome/browser/extensions/api/messaging/incognito_connectability.h" | 5 #include "chrome/browser/extensions/api/messaging/incognito_connectability.h" |
| 6 | 6 |
| 7 #include "base/lazy_instance.h" | 7 #include "base/lazy_instance.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/strings/string16.h" | 9 #include "base/strings/string16.h" |
| 10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 111 ExtensionToOriginsMap::const_iterator it = map.find(extension->id()); | 111 ExtensionToOriginsMap::const_iterator it = map.find(extension->id()); |
| 112 return it != map.end() && it->second.count(origin) > 0; | 112 return it != map.end() && it->second.count(origin) > 0; |
| 113 } | 113 } |
| 114 | 114 |
| 115 static base::LazyInstance<ProfileKeyedAPIFactory<IncognitoConnectability> > | 115 static base::LazyInstance<ProfileKeyedAPIFactory<IncognitoConnectability> > |
| 116 g_factory = LAZY_INSTANCE_INITIALIZER; | 116 g_factory = LAZY_INSTANCE_INITIALIZER; |
| 117 | 117 |
| 118 // static | 118 // static |
| 119 ProfileKeyedAPIFactory<IncognitoConnectability>* | 119 ProfileKeyedAPIFactory<IncognitoConnectability>* |
| 120 IncognitoConnectability::GetFactoryInstance() { | 120 IncognitoConnectability::GetFactoryInstance() { |
| 121 return &g_factory.Get(); | 121 return g_factory.Pointer(); |
| 122 } | 122 } |
| 123 | 123 |
| 124 } // namespace extensions | 124 } // namespace extensions |
| OLD | NEW |