| OLD | NEW |
| 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 "chrome/common/extensions/permissions/permission_set.h" | 5 #include "chrome/common/extensions/permissions/permission_set.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <iterator> | 8 #include <iterator> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 const char* kNonPermissionModuleNames[] = { | 40 const char* kNonPermissionModuleNames[] = { |
| 41 "browserAction", | 41 "browserAction", |
| 42 "commands", | 42 "commands", |
| 43 "devtools", | 43 "devtools", |
| 44 "events", | 44 "events", |
| 45 "extension", | 45 "extension", |
| 46 "i18n", | 46 "i18n", |
| 47 "omnibox", | 47 "omnibox", |
| 48 "pageAction", | 48 "pageAction", |
| 49 "pageActions", | 49 "pageActions", |
| 50 "pageLauncher", |
| 50 "permissions", | 51 "permissions", |
| 51 "runtime", | 52 "runtime", |
| 52 "scriptBadge", | 53 "scriptBadge", |
| 53 "tabs", | 54 "tabs", |
| 54 "test", | 55 "test", |
| 55 "types", | 56 "types", |
| 56 "windows" | 57 "windows" |
| 57 }; | 58 }; |
| 58 const size_t kNumNonPermissionModuleNames = | 59 const size_t kNumNonPermissionModuleNames = |
| 59 arraysize(kNonPermissionModuleNames); | 60 arraysize(kNonPermissionModuleNames); |
| (...skipping 547 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 607 std::set<std::string> new_hosts_only; | 608 std::set<std::string> new_hosts_only; |
| 608 | 609 |
| 609 std::set_difference(new_hosts_set.begin(), new_hosts_set.end(), | 610 std::set_difference(new_hosts_set.begin(), new_hosts_set.end(), |
| 610 old_hosts_set.begin(), old_hosts_set.end(), | 611 old_hosts_set.begin(), old_hosts_set.end(), |
| 611 std::inserter(new_hosts_only, new_hosts_only.begin())); | 612 std::inserter(new_hosts_only, new_hosts_only.begin())); |
| 612 | 613 |
| 613 return !new_hosts_only.empty(); | 614 return !new_hosts_only.empty(); |
| 614 } | 615 } |
| 615 | 616 |
| 616 } // namespace extensions | 617 } // namespace extensions |
| OLD | NEW |