| 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 "android_webview/lib/main/aw_main_delegate.h" | 5 #include "android_webview/lib/main/aw_main_delegate.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 | 8 |
| 9 #include "android_webview/browser/aw_content_browser_client.h" | 9 #include "android_webview/browser/aw_content_browser_client.h" |
| 10 #include "android_webview/browser/browser_view_renderer.h" | 10 #include "android_webview/browser/browser_view_renderer.h" |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 // cpu_brand info. | 146 // cpu_brand info. |
| 147 base::CPU cpu_info; | 147 base::CPU cpu_info; |
| 148 #endif | 148 #endif |
| 149 | 149 |
| 150 const base::CommandLine& command_line = | 150 const base::CommandLine& command_line = |
| 151 *base::CommandLine::ForCurrentProcess(); | 151 *base::CommandLine::ForCurrentProcess(); |
| 152 std::string process_type = | 152 std::string process_type = |
| 153 command_line.GetSwitchValueASCII(switches::kProcessType); | 153 command_line.GetSwitchValueASCII(switches::kProcessType); |
| 154 int crash_signal_fd = -1; | 154 int crash_signal_fd = -1; |
| 155 if (process_type == switches::kRendererProcess) { | 155 if (process_type == switches::kRendererProcess) { |
| 156 auto global_descriptors = base::GlobalDescriptors::GetInstance(); | 156 auto* global_descriptors = base::GlobalDescriptors::GetInstance(); |
| 157 int pak_fd = global_descriptors->Get(kAndroidWebViewLocalePakDescriptor); | 157 int pak_fd = global_descriptors->Get(kAndroidWebViewLocalePakDescriptor); |
| 158 base::MemoryMappedFile::Region pak_region = | 158 base::MemoryMappedFile::Region pak_region = |
| 159 global_descriptors->GetRegion(kAndroidWebViewLocalePakDescriptor); | 159 global_descriptors->GetRegion(kAndroidWebViewLocalePakDescriptor); |
| 160 ResourceBundle::InitSharedInstanceWithPakFileRegion(base::File(pak_fd), | 160 ResourceBundle::InitSharedInstanceWithPakFileRegion(base::File(pak_fd), |
| 161 pak_region); | 161 pak_region); |
| 162 pak_fd = global_descriptors->Get(kAndroidWebViewMainPakDescriptor); | 162 pak_fd = global_descriptors->Get(kAndroidWebViewMainPakDescriptor); |
| 163 pak_region = | 163 pak_region = |
| 164 global_descriptors->GetRegion(kAndroidWebViewMainPakDescriptor); | 164 global_descriptors->GetRegion(kAndroidWebViewMainPakDescriptor); |
| 165 ResourceBundle::GetSharedInstance().AddDataPackFromFileRegion( | 165 ResourceBundle::GetSharedInstance().AddDataPackFromFileRegion( |
| 166 base::File(pak_fd), pak_region, ui::SCALE_FACTOR_NONE); | 166 base::File(pak_fd), pak_region, ui::SCALE_FACTOR_NONE); |
| (...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 259 #if defined(VIDEO_HOLE) | 259 #if defined(VIDEO_HOLE) |
| 260 content::ExternalVideoSurfaceContainer* | 260 content::ExternalVideoSurfaceContainer* |
| 261 AwMainDelegate::CreateExternalVideoSurfaceContainer( | 261 AwMainDelegate::CreateExternalVideoSurfaceContainer( |
| 262 content::WebContents* web_contents) { | 262 content::WebContents* web_contents) { |
| 263 return external_video_surface::ExternalVideoSurfaceContainerImpl::Create( | 263 return external_video_surface::ExternalVideoSurfaceContainerImpl::Create( |
| 264 web_contents); | 264 web_contents); |
| 265 } | 265 } |
| 266 #endif | 266 #endif |
| 267 | 267 |
| 268 } // namespace android_webview | 268 } // namespace android_webview |
| OLD | NEW |