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

Side by Side Diff: content/renderer/render_view_impl.h

Issue 8774050: Pass along the referrer policy (renderer side) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates Created 9 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ 5 #ifndef CONTENT_RENDERER_RENDER_VIEW_IMPL_H_
6 #define CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ 6 #define CONTENT_RENDERER_RENDER_VIEW_IMPL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <deque> 9 #include <deque>
10 #include <map> 10 #include <map>
11 #include <queue> 11 #include <queue>
12 #include <set> 12 #include <set>
13 #include <string> 13 #include <string>
14 #include <vector> 14 #include <vector>
15 15
16 #include "base/basictypes.h" 16 #include "base/basictypes.h"
17 #include "base/gtest_prod_util.h" 17 #include "base/gtest_prod_util.h"
18 #include "base/id_map.h" 18 #include "base/id_map.h"
19 #include "base/memory/linked_ptr.h" 19 #include "base/memory/linked_ptr.h"
20 #include "base/memory/weak_ptr.h" 20 #include "base/memory/weak_ptr.h"
21 #include "base/observer_list.h" 21 #include "base/observer_list.h"
22 #include "base/timer.h" 22 #include "base/timer.h"
23 #include "build/build_config.h" 23 #include "build/build_config.h"
24 #include "content/renderer/render_view_selection.h" 24 #include "content/renderer/render_view_selection.h"
25 #include "content/renderer/renderer_webcookiejar_impl.h" 25 #include "content/renderer/renderer_webcookiejar_impl.h"
26 #include "content/common/content_export.h" 26 #include "content/common/content_export.h"
27 #include "content/common/edit_command.h" 27 #include "content/common/edit_command.h"
28 #include "content/common/navigation_gesture.h" 28 #include "content/common/navigation_gesture.h"
29 #include "content/public/common/page_zoom.h" 29 #include "content/public/common/page_zoom.h"
30 #include "content/public/common/referrer.h"
30 #include "content/public/common/renderer_preferences.h" 31 #include "content/public/common/renderer_preferences.h"
31 #include "content/public/common/stop_find_action.h" 32 #include "content/public/common/stop_find_action.h"
32 #include "content/public/renderer/render_view.h" 33 #include "content/public/renderer/render_view.h"
33 #include "content/renderer/pepper_plugin_delegate_impl.h" 34 #include "content/renderer/pepper_plugin_delegate_impl.h"
34 #include "content/renderer/render_widget.h" 35 #include "content/renderer/render_widget.h"
35 #include "ipc/ipc_platform_file.h" 36 #include "ipc/ipc_platform_file.h"
36 #include "third_party/WebKit/Source/WebKit/chromium/public/WebConsoleMessage.h" 37 #include "third_party/WebKit/Source/WebKit/chromium/public/WebConsoleMessage.h"
37 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFileSystem.h" 38 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFileSystem.h"
38 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrameClient.h" 39 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrameClient.h"
39 #include "third_party/WebKit/Source/WebKit/chromium/public/WebIconURL.h" 40 #include "third_party/WebKit/Source/WebKit/chromium/public/WebIconURL.h"
(...skipping 675 matching lines...) Expand 10 before | Expand all | Expand 10 after
715 // title tags will follow meta tags. In here we try to get encoding of 716 // title tags will follow meta tags. In here we try to get encoding of
716 // page if it has been specified in meta tag. 717 // page if it has been specified in meta tag.
717 // c) function:DidFinishDocumentLoadForFrame. When this function is 718 // c) function:DidFinishDocumentLoadForFrame. When this function is
718 // called, that means we have got whole html page. In here we should 719 // called, that means we have got whole html page. In here we should
719 // finally get right encoding of page. 720 // finally get right encoding of page.
720 void UpdateEncoding(WebKit::WebFrame* frame, 721 void UpdateEncoding(WebKit::WebFrame* frame,
721 const std::string& encoding_name); 722 const std::string& encoding_name);
722 723
723 void OpenURL(WebKit::WebFrame* frame, 724 void OpenURL(WebKit::WebFrame* frame,
724 const GURL& url, 725 const GURL& url,
725 const GURL& referrer, 726 const content::Referrer& referrer,
726 WebKit::WebNavigationPolicy policy); 727 WebKit::WebNavigationPolicy policy);
727 728
728 bool RunJavaScriptMessage(int type, 729 bool RunJavaScriptMessage(int type,
729 const string16& message, 730 const string16& message,
730 const string16& default_value, 731 const string16& default_value,
731 const GURL& frame_url, 732 const GURL& frame_url,
732 string16* result); 733 string16* result);
733 734
734 // Sends a message and runs a nested message loop. 735 // Sends a message and runs a nested message loop.
735 bool SendAndRunNestedMessageLoop(IPC::SyncMessage* message); 736 bool SendAndRunNestedMessageLoop(IPC::SyncMessage* message);
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
1033 1034
1034 // Whether this RenderView was created by a frame that was suppressing its 1035 // Whether this RenderView was created by a frame that was suppressing its
1035 // opener. If so, we may want to load pages in a separate process. See 1036 // opener. If so, we may want to load pages in a separate process. See
1036 // decidePolicyForNavigation for details. 1037 // decidePolicyForNavigation for details.
1037 bool opener_suppressed_; 1038 bool opener_suppressed_;
1038 1039
1039 // If we are handling a top-level client-side redirect, this tracks the URL 1040 // If we are handling a top-level client-side redirect, this tracks the URL
1040 // of the page that initiated it. Specifically, when a load is committed this 1041 // of the page that initiated it. Specifically, when a load is committed this
1041 // is used to determine if that load originated from a client-side redirect. 1042 // is used to determine if that load originated from a client-side redirect.
1042 // It is empty if there is no top-level client-side redirect. 1043 // It is empty if there is no top-level client-side redirect.
1043 GURL completed_client_redirect_src_; 1044 content::Referrer completed_client_redirect_src_;
1044 1045
1045 // Holds state pertaining to a navigation that we initiated. This is held by 1046 // Holds state pertaining to a navigation that we initiated. This is held by
1046 // the WebDataSource::ExtraData attribute. We use pending_navigation_state_ 1047 // the WebDataSource::ExtraData attribute. We use pending_navigation_state_
1047 // as a temporary holder for the state until the WebDataSource corresponding 1048 // as a temporary holder for the state until the WebDataSource corresponding
1048 // to the new navigation is created. See DidCreateDataSource. 1049 // to the new navigation is created. See DidCreateDataSource.
1049 scoped_ptr<ViewMsg_Navigate_Params> pending_navigation_params_; 1050 scoped_ptr<ViewMsg_Navigate_Params> pending_navigation_params_;
1050 1051
1051 // Timer used to delay the updating of nav state (see SyncNavigationState). 1052 // Timer used to delay the updating of nav state (see SyncNavigationState).
1052 base::OneShotTimer<RenderViewImpl> nav_state_sync_timer_; 1053 base::OneShotTimer<RenderViewImpl> nav_state_sync_timer_;
1053 1054
(...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after
1266 // bunch of stuff, you should probably create a helper class and put your 1267 // bunch of stuff, you should probably create a helper class and put your
1267 // data and methods on that to avoid bloating RenderView more. You can 1268 // data and methods on that to avoid bloating RenderView more. You can
1268 // use the Observer interface to filter IPC messages and receive frame change 1269 // use the Observer interface to filter IPC messages and receive frame change
1269 // notifications. 1270 // notifications.
1270 // --------------------------------------------------------------------------- 1271 // ---------------------------------------------------------------------------
1271 1272
1272 DISALLOW_COPY_AND_ASSIGN(RenderViewImpl); 1273 DISALLOW_COPY_AND_ASSIGN(RenderViewImpl);
1273 }; 1274 };
1274 1275
1275 #endif // CONTENT_RENDERER_RENDER_VIEW_IMPL_H_ 1276 #endif // CONTENT_RENDERER_RENDER_VIEW_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698