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 "android_webview/browser/aw_content_browser_client.h" | 7 #include "android_webview/browser/aw_content_browser_client.h" |
8 #include "android_webview/browser/browser_view_renderer.h" | 8 #include "android_webview/browser/browser_view_renderer.h" |
9 #include "android_webview/browser/scoped_allow_wait_for_legacy_web_view_api.h" | 9 #include "android_webview/browser/scoped_allow_wait_for_legacy_web_view_api.h" |
10 #include "android_webview/lib/aw_browser_dependency_factory_impl.h" | 10 #include "android_webview/lib/aw_browser_dependency_factory_impl.h" |
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
53 bool AwMainDelegate::BasicStartupComplete(int* exit_code) { | 53 bool AwMainDelegate::BasicStartupComplete(int* exit_code) { |
54 content::SetContentClient(&content_client_); | 54 content::SetContentClient(&content_client_); |
55 | 55 |
56 content::BrowserMediaPlayerManager::RegisterMediaUrlInterceptor( | 56 content::BrowserMediaPlayerManager::RegisterMediaUrlInterceptor( |
57 new AwMediaUrlInterceptor()); | 57 new AwMediaUrlInterceptor()); |
58 | 58 |
59 BrowserViewRenderer::CalculateTileMemoryPolicy(); | 59 BrowserViewRenderer::CalculateTileMemoryPolicy(); |
60 | 60 |
61 base::CommandLine* cl = base::CommandLine::ForCurrentProcess(); | 61 base::CommandLine* cl = base::CommandLine::ForCurrentProcess(); |
62 cl->AppendSwitch(switches::kEnableBeginFrameScheduling); | 62 cl->AppendSwitch(switches::kEnableBeginFrameScheduling); |
63 cl->AppendSwitch(switches::kEnableImplSidePainting); | |
64 | 63 |
65 // WebView uses the Android system's scrollbars and overscroll glow. | 64 // WebView uses the Android system's scrollbars and overscroll glow. |
66 cl->AppendSwitch(switches::kDisableOverscrollEdgeEffect); | 65 cl->AppendSwitch(switches::kDisableOverscrollEdgeEffect); |
67 | 66 |
68 // Pull-to-refresh should never be a default WebView action. | 67 // Pull-to-refresh should never be a default WebView action. |
69 cl->AppendSwitch(switches::kDisablePullToRefreshEffect); | 68 cl->AppendSwitch(switches::kDisablePullToRefreshEffect); |
70 | 69 |
71 // Not yet supported in single-process mode. | 70 // Not yet supported in single-process mode. |
72 cl->AppendSwitch(switches::kDisableSharedWorkers); | 71 cl->AppendSwitch(switches::kDisableSharedWorkers); |
73 | 72 |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
174 | 173 |
175 #if defined(VIDEO_HOLE) | 174 #if defined(VIDEO_HOLE) |
176 content::ExternalVideoSurfaceContainer* | 175 content::ExternalVideoSurfaceContainer* |
177 AwMainDelegate::CreateExternalVideoSurfaceContainer( | 176 AwMainDelegate::CreateExternalVideoSurfaceContainer( |
178 content::WebContents* web_contents) { | 177 content::WebContents* web_contents) { |
179 return new ExternalVideoSurfaceContainerImpl(web_contents); | 178 return new ExternalVideoSurfaceContainerImpl(web_contents); |
180 } | 179 } |
181 #endif | 180 #endif |
182 | 181 |
183 } // namespace android_webview | 182 } // namespace android_webview |
OLD | NEW |