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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2464693004: Fix mojom::ResourceUsageReporter exposure via content child capabilities (Closed)
Patch Set: . Created 4 years, 1 month 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 (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/browser/chrome_content_browser_client.h" 5 #include "chrome/browser/chrome_content_browser_client.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 3000 matching lines...) Expand 10 before | Expand all | Expand 10 after
3011 3011
3012 std::unique_ptr<base::Value> 3012 std::unique_ptr<base::Value>
3013 ChromeContentBrowserClient::GetServiceManifestOverlay( 3013 ChromeContentBrowserClient::GetServiceManifestOverlay(
3014 const std::string& name) { 3014 const std::string& name) {
3015 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); 3015 ResourceBundle& rb = ResourceBundle::GetSharedInstance();
3016 int id = -1; 3016 int id = -1;
3017 if (name == content::kBrowserServiceName) 3017 if (name == content::kBrowserServiceName)
3018 id = IDR_CHROME_CONTENT_BROWSER_MANIFEST_OVERLAY; 3018 id = IDR_CHROME_CONTENT_BROWSER_MANIFEST_OVERLAY;
3019 else if (name == content::kGpuServiceName) 3019 else if (name == content::kGpuServiceName)
3020 id = IDR_CHROME_CONTENT_GPU_MANIFEST_OVERLAY; 3020 id = IDR_CHROME_CONTENT_GPU_MANIFEST_OVERLAY;
3021 else if (name == content::kPluginServiceName)
3022 id = IDR_CHROME_CONTENT_PLUGIN_MANIFEST_OVERLAY;
3021 else if (name == content::kRendererServiceName) 3023 else if (name == content::kRendererServiceName)
3022 id = IDR_CHROME_CONTENT_RENDERER_MANIFEST_OVERLAY; 3024 id = IDR_CHROME_CONTENT_RENDERER_MANIFEST_OVERLAY;
3023 else if (name == content::kUtilityServiceName) 3025 else if (name == content::kUtilityServiceName)
3024 id = IDR_CHROME_CONTENT_UTILITY_MANIFEST_OVERLAY; 3026 id = IDR_CHROME_CONTENT_UTILITY_MANIFEST_OVERLAY;
3025 if (id == -1) 3027 if (id == -1)
3026 return nullptr; 3028 return nullptr;
3027 3029
3028 base::StringPiece manifest_contents = 3030 base::StringPiece manifest_contents =
3029 rb.GetRawDataResourceForScale(id, ui::ScaleFactor::SCALE_FACTOR_NONE); 3031 rb.GetRawDataResourceForScale(id, ui::ScaleFactor::SCALE_FACTOR_NONE);
3030 return base::JSONReader::Read(manifest_contents); 3032 return base::JSONReader::Read(manifest_contents);
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
3227 kWebRtcDevSwitchNames, 3229 kWebRtcDevSwitchNames,
3228 arraysize(kWebRtcDevSwitchNames)); 3230 arraysize(kWebRtcDevSwitchNames));
3229 } 3231 }
3230 } 3232 }
3231 #endif // defined(ENABLE_WEBRTC) 3233 #endif // defined(ENABLE_WEBRTC)
3232 3234
3233 std::unique_ptr<content::MemoryCoordinatorDelegate> 3235 std::unique_ptr<content::MemoryCoordinatorDelegate>
3234 ChromeContentBrowserClient::GetMemoryCoordinatorDelegate() { 3236 ChromeContentBrowserClient::GetMemoryCoordinatorDelegate() {
3235 return memory::ChromeMemoryCoordinatorDelegate::Create(); 3237 return memory::ChromeMemoryCoordinatorDelegate::Create();
3236 } 3238 }
OLDNEW
« no previous file with comments | « chrome/browser/browser_resources.grd ('k') | chrome/browser/chrome_content_gpu_manifest_overlay.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698