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

Side by Side Diff: content/public/browser/page_navigator.h

Issue 21378002: Support POST in browser navaigation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 4 months 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 // PageNavigator defines an interface that can be used to express the user's 5 // PageNavigator defines an interface that can be used to express the user's
6 // intention to navigate to a particular URL. The implementing class should 6 // intention to navigate to a particular URL. The implementing class should
7 // perform the navigation. 7 // perform the navigation.
8 8
9 #ifndef CONTENT_PUBLIC_BROWSER_PAGE_NAVIGATOR_H_ 9 #ifndef CONTENT_PUBLIC_BROWSER_PAGE_NAVIGATOR_H_
10 #define CONTENT_PUBLIC_BROWSER_PAGE_NAVIGATOR_H_ 10 #define CONTENT_PUBLIC_BROWSER_PAGE_NAVIGATOR_H_
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 GlobalRequestID transferred_global_request_id; 65 GlobalRequestID transferred_global_request_id;
66 66
67 // Indicates whether this navigation should replace the current 67 // Indicates whether this navigation should replace the current
68 // navigation entry. 68 // navigation entry.
69 bool should_replace_current_entry; 69 bool should_replace_current_entry;
70 70
71 // Indicates whether this navigation was triggered while processing a user 71 // Indicates whether this navigation was triggered while processing a user
72 // gesture if the navigation was initiated by the renderer. 72 // gesture if the navigation was initiated by the renderer.
73 bool user_gesture; 73 bool user_gesture;
74 74
75 // Indicates whether this navigation will be sent using POST.
76 bool uses_post;
77
78 // The post data when the navigation uses POST.
79 // Checking empty status of |post_data| should be enough to indicates whether
80 // opening a URL uses POST if sending POSt without data is disallowed.
Avi (use Gerrit) 2013/07/31 19:35:18 POSt?
Johnny(Jianning) Ding 2013/07/31 20:42:47 typo fixed. The question is that do we allow send
81 std::string post_data;
82
75 private: 83 private:
76 OpenURLParams(); 84 OpenURLParams();
77 }; 85 };
78 86
79 class PageNavigator { 87 class PageNavigator {
80 public: 88 public:
81 virtual ~PageNavigator() {} 89 virtual ~PageNavigator() {}
82 90
83 // Opens a URL with the given disposition. The transition specifies how this 91 // Opens a URL with the given disposition. The transition specifies how this
84 // navigation should be recorded in the history system (for example, typed). 92 // navigation should be recorded in the history system (for example, typed).
85 // Returns the WebContents the URL is opened in, or NULL if the URL wasn't 93 // Returns the WebContents the URL is opened in, or NULL if the URL wasn't
86 // opened immediately. 94 // opened immediately.
87 virtual WebContents* OpenURL(const OpenURLParams& params) = 0; 95 virtual WebContents* OpenURL(const OpenURLParams& params) = 0;
88 }; 96 };
89 97
90 } 98 }
91 99
92 #endif // CONTENT_PUBLIC_BROWSER_PAGE_NAVIGATOR_H_ 100 #endif // CONTENT_PUBLIC_BROWSER_PAGE_NAVIGATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698