mirror of
				https://bitbucket.org/chromiumembedded/cef
				synced 2025-06-05 21:39:12 +02:00 
			
		
		
		
	Update to Chromium revision 167921.
git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@907 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
		| @@ -26,11 +26,6 @@ patches = [ | ||||
|     'name': 'zlib', | ||||
|     'path': '../third_party/zlib/', | ||||
|   }, | ||||
|   { | ||||
|     # https://codereview.chromium.org/11293157/ | ||||
|     'name': 'content_navigation', | ||||
|     'path': '../content/', | ||||
|   }, | ||||
|   { | ||||
|     # http://code.google.com/p/chromiumembedded/issues/detail?id=364 | ||||
|     'name': 'spi_webcore_364', | ||||
|   | ||||
| @@ -1,66 +0,0 @@ | ||||
| Index: public/renderer/content_renderer_client.cc | ||||
| =================================================================== | ||||
| --- public/renderer/content_renderer_client.cc	(revision 165669) | ||||
| +++ public/renderer/content_renderer_client.cc	(working copy) | ||||
| @@ -56,6 +56,15 @@ | ||||
|    return false; | ||||
|  } | ||||
|   | ||||
| +bool ContentRendererClient::HandleNavigation( | ||||
| +    WebKit::WebFrame* frame, | ||||
| +    const WebKit::WebURLRequest& request, | ||||
| +    WebKit::WebNavigationType type, | ||||
| +    WebKit::WebNavigationPolicy default_policy, | ||||
| +    bool is_redirect) { | ||||
| +  return false; | ||||
| +} | ||||
| + | ||||
|  bool ContentRendererClient::ShouldFork(WebKit::WebFrame* frame, | ||||
|                                         const GURL& url, | ||||
|                                         bool is_initial_navigation, | ||||
| Index: public/renderer/content_renderer_client.h | ||||
| =================================================================== | ||||
| --- public/renderer/content_renderer_client.h	(revision 165669) | ||||
| +++ public/renderer/content_renderer_client.h	(working copy) | ||||
| @@ -12,6 +12,8 @@ | ||||
|  #include "ipc/ipc_message.h" | ||||
|  #include "content/public/common/content_client.h" | ||||
|  #include "content/public/common/page_transition_types.h" | ||||
| +#include "third_party/WebKit/Source/WebKit/chromium/public/WebNavigationPolicy.h" | ||||
| +#include "third_party/WebKit/Source/WebKit/chromium/public/WebNavigationType.h" | ||||
|  #include "third_party/WebKit/Source/WebKit/chromium/public/WebPageVisibilityState.h" | ||||
|  #include "v8/include/v8.h" | ||||
|   | ||||
| @@ -130,6 +132,14 @@ | ||||
|    // Returns true if the given url can create popup windows. | ||||
|    virtual bool AllowPopup(const GURL& creator); | ||||
|   | ||||
| +  // Returns true if the navigation was handled by the embedder and should be | ||||
| +  // ignored by WebKit. This method is used by CEF. | ||||
| +  virtual bool HandleNavigation(WebKit::WebFrame* frame, | ||||
| +                                const WebKit::WebURLRequest& request, | ||||
| +                                WebKit::WebNavigationType type, | ||||
| +                                WebKit::WebNavigationPolicy default_policy, | ||||
| +                                bool is_redirect); | ||||
| + | ||||
|    // Returns true if we should fork a new process for the given navigation. | ||||
|    virtual bool ShouldFork(WebKit::WebFrame* frame, | ||||
|                            const GURL& url, | ||||
| Index: renderer/render_view_impl.cc | ||||
| =================================================================== | ||||
| --- renderer/render_view_impl.cc	(revision 165669) | ||||
| +++ renderer/render_view_impl.cc	(working copy) | ||||
| @@ -2674,6 +2674,13 @@ | ||||
|  WebNavigationPolicy RenderViewImpl::decidePolicyForNavigation( | ||||
|      WebFrame* frame, const WebURLRequest& request, WebNavigationType type, | ||||
|      const WebNode&, WebNavigationPolicy default_policy, bool is_redirect) { | ||||
| +  if (request.url() != GURL(kSwappedOutURL) && | ||||
| +      GetContentClient()->renderer()->HandleNavigation(frame, request, type, | ||||
| +                                                       default_policy, | ||||
| +                                                       is_redirect)) { | ||||
| +    return WebKit::WebNavigationPolicyIgnore; | ||||
| +  } | ||||
| + | ||||
|    Referrer referrer( | ||||
|        GURL(request.httpHeaderField(WebString::fromUTF8("Referer"))), | ||||
|        GetReferrerPolicyFromRequest(frame, request)); | ||||
		Reference in New Issue
	
	Block a user