OLD | NEW |
---|---|
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 "extensions/common/features/json_feature_provider_source.h" | 5 #include "extensions/common/features/json_feature_provider_source.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
Yoyo Zhou
2014/05/12 17:19:46
Generally if we include a header in the .h file, w
| |
8 | 8 |
9 #include "base/json/json_reader.h" | 9 #include "base/json/json_reader.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
11 #include "ui/base/resource/resource_bundle.h" | 11 #include "ui/base/resource/resource_bundle.h" |
12 | 12 |
13 namespace extensions { | 13 namespace extensions { |
14 | 14 |
15 JSONFeatureProviderSource::JSONFeatureProviderSource(const std::string& name) | 15 JSONFeatureProviderSource::JSONFeatureProviderSource(const std::string& name) |
16 : name_(name) { | 16 : name_(name) { |
17 } | 17 } |
(...skipping 26 matching lines...) Expand all Loading... | |
44 iter.Advance()) { | 44 iter.Advance()) { |
45 if (dictionary_.GetWithoutPathExpansion(iter.key(), NULL)) | 45 if (dictionary_.GetWithoutPathExpansion(iter.key(), NULL)) |
46 LOG(FATAL) << "Key " << iter.key() << " is defined in " << name_ | 46 LOG(FATAL) << "Key " << iter.key() << " is defined in " << name_ |
47 << " JSON feature files more than once."; | 47 << " JSON feature files more than once."; |
48 } | 48 } |
49 | 49 |
50 // Merge. | 50 // Merge. |
51 dictionary_.MergeDictionary(value_as_dict.get()); | 51 dictionary_.MergeDictionary(value_as_dict.get()); |
52 } | 52 } |
53 | 53 |
54 } // namespace | 54 } // namespace extensions |
OLD | NEW |