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

Side by Side Diff: android_webview/browser/aw_content_browser_client.cc

Issue 11471040: [Android WebView] Convert context menu callback to long press (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix findbugs by not passing native pointer. Created 8 years 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 | Annotate | Revision Log
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 "android_webview/browser/aw_content_browser_client.h" 5 #include "android_webview/browser/aw_content_browser_client.h"
6 6
7 #include "android_webview/browser/aw_browser_main_parts.h" 7 #include "android_webview/browser/aw_browser_main_parts.h"
8 #include "android_webview/browser/aw_cookie_access_policy.h" 8 #include "android_webview/browser/aw_cookie_access_policy.h"
9 #include "android_webview/browser/aw_quota_permission_context.h" 9 #include "android_webview/browser/aw_quota_permission_context.h"
10 #include "android_webview/browser/aw_web_contents_view_delegate_factory.h"
10 #include "android_webview/browser/net_disk_cache_remover.h" 11 #include "android_webview/browser/net_disk_cache_remover.h"
11 #include "android_webview/browser/renderer_host/aw_resource_dispatcher_host_dele gate.h" 12 #include "android_webview/browser/renderer_host/aw_resource_dispatcher_host_dele gate.h"
12 #include "android_webview/common/url_constants.h" 13 #include "android_webview/common/url_constants.h"
13 #include "base/base_paths_android.h" 14 #include "base/base_paths_android.h"
14 #include "base/path_service.h" 15 #include "base/path_service.h"
15 #include "content/public/browser/access_token_store.h" 16 #include "content/public/browser/access_token_store.h"
16 #include "content/public/browser/child_process_security_policy.h" 17 #include "content/public/browser/child_process_security_policy.h"
17 #include "content/public/browser/render_process_host.h" 18 #include "content/public/browser/render_process_host.h"
18 #include "content/public/browser/render_view_host.h" 19 #include "content/public/browser/render_view_host.h"
19 #include "content/public/common/url_constants.h" 20 #include "content/public/common/url_constants.h"
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
55 56
56 AwBrowserContext* AwContentBrowserClient::GetAwBrowserContext() { 57 AwBrowserContext* AwContentBrowserClient::GetAwBrowserContext() {
57 return browser_context_.get(); 58 return browser_context_.get();
58 } 59 }
59 60
60 content::BrowserMainParts* AwContentBrowserClient::CreateBrowserMainParts( 61 content::BrowserMainParts* AwContentBrowserClient::CreateBrowserMainParts(
61 const content::MainFunctionParams& parameters) { 62 const content::MainFunctionParams& parameters) {
62 return new AwBrowserMainParts(browser_context_.get()); 63 return new AwBrowserMainParts(browser_context_.get());
63 } 64 }
64 65
66 content::WebContentsViewDelegate*
67 AwContentBrowserClient::GetWebContentsViewDelegate(
68 content::WebContents* web_contents) {
69 return CreateAwWebContentsViewDelegate(web_contents);
joth 2012/12/11 01:22:11 this works ok.. but rather than call straight out
boliu 2012/12/11 02:25:34 Choosing callback since it's easier. One snag in
70 }
71
65 void AwContentBrowserClient::RenderProcessHostCreated( 72 void AwContentBrowserClient::RenderProcessHostCreated(
66 content::RenderProcessHost* host) { 73 content::RenderProcessHost* host) {
67 // If WebView becomes multi-process capable, this may be insecure. 74 // If WebView becomes multi-process capable, this may be insecure.
68 // More benefit can be derived from the ChildProcessSecurotyPolicy by 75 // More benefit can be derived from the ChildProcessSecurotyPolicy by
69 // deferring the GrantScheme calls until we know that a given child process 76 // deferring the GrantScheme calls until we know that a given child process
70 // really does need that priviledge. Check here to ensure we rethink this 77 // really does need that priviledge. Check here to ensure we rethink this
71 // when the time comes. See crbug.com/156062. 78 // when the time comes. See crbug.com/156062.
72 CHECK(content::RenderProcessHost::run_renderer_in_process()); 79 CHECK(content::RenderProcessHost::run_renderer_in_process());
73 80
74 // Grant content: and file: scheme to the whole process, since we impose 81 // Grant content: and file: scheme to the whole process, since we impose
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after
322 329
323 bool AwContentBrowserClient::AllowPepperSocketAPI( 330 bool AwContentBrowserClient::AllowPepperSocketAPI(
324 content::BrowserContext* browser_context, 331 content::BrowserContext* browser_context,
325 const GURL& url, 332 const GURL& url,
326 const content::SocketPermissionRequest& params) { 333 const content::SocketPermissionRequest& params) {
327 NOTREACHED() << "Android WebView does not support plugins"; 334 NOTREACHED() << "Android WebView does not support plugins";
328 return false; 335 return false;
329 } 336 }
330 337
331 } // namespace android_webview 338 } // namespace android_webview
OLDNEW
« no previous file with comments | « android_webview/browser/aw_content_browser_client.h ('k') | android_webview/browser/aw_web_contents_view_delegate_factory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698