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 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
59 } | 59 } |
60 | 60 |
61 AwMainDelegate::~AwMainDelegate() { | 61 AwMainDelegate::~AwMainDelegate() { |
62 } | 62 } |
63 | 63 |
64 bool AwMainDelegate::BasicStartupComplete(int* exit_code) { | 64 bool AwMainDelegate::BasicStartupComplete(int* exit_code) { |
65 content::SetContentClient(&content_client_); | 65 content::SetContentClient(&content_client_); |
66 | 66 |
67 base::CommandLine* cl = base::CommandLine::ForCurrentProcess(); | 67 base::CommandLine* cl = base::CommandLine::ForCurrentProcess(); |
68 | 68 |
| 69 // Enable async OnDraw by default. See crbug.com/636164 for progress. |
| 70 cl->AppendSwitch(switches::kAsyncOnDrawHardware); |
| 71 |
69 // WebView uses the Android system's scrollbars and overscroll glow. | 72 // WebView uses the Android system's scrollbars and overscroll glow. |
70 cl->AppendSwitch(switches::kDisableOverscrollEdgeEffect); | 73 cl->AppendSwitch(switches::kDisableOverscrollEdgeEffect); |
71 | 74 |
72 // Pull-to-refresh should never be a default WebView action. | 75 // Pull-to-refresh should never be a default WebView action. |
73 cl->AppendSwitch(switches::kDisablePullToRefreshEffect); | 76 cl->AppendSwitch(switches::kDisablePullToRefreshEffect); |
74 | 77 |
75 // Not yet supported in single-process mode. | 78 // Not yet supported in single-process mode. |
76 cl->AppendSwitch(switches::kDisableSharedWorkers); | 79 cl->AppendSwitch(switches::kDisableSharedWorkers); |
77 | 80 |
78 // File system API not supported (requires some new API; internal bug 6930981) | 81 // File system API not supported (requires some new API; internal bug 6930981) |
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 | 262 |
260 AwWebPreferencesPopulater* AwMainDelegate::CreateWebPreferencesPopulater() { | 263 AwWebPreferencesPopulater* AwMainDelegate::CreateWebPreferencesPopulater() { |
261 return new AwWebPreferencesPopulaterImpl(); | 264 return new AwWebPreferencesPopulaterImpl(); |
262 } | 265 } |
263 | 266 |
264 AwLocaleManager* AwMainDelegate::CreateAwLocaleManager() { | 267 AwLocaleManager* AwMainDelegate::CreateAwLocaleManager() { |
265 return new AwLocaleManagerImpl(); | 268 return new AwLocaleManagerImpl(); |
266 } | 269 } |
267 | 270 |
268 } // namespace android_webview | 271 } // namespace android_webview |
OLD | NEW |