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

Side by Side Diff: chrome/browser/ui/browser_navigator.h

Issue 21378002: Support POST in browser navaigation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: move PageNavigator Destructor body back 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
« no previous file with comments | « no previous file | chrome/browser/ui/browser_navigator.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #ifndef CHROME_BROWSER_UI_BROWSER_NAVIGATOR_H_ 5 #ifndef CHROME_BROWSER_UI_BROWSER_NAVIGATOR_H_
6 #define CHROME_BROWSER_UI_BROWSER_NAVIGATOR_H_ 6 #define CHROME_BROWSER_UI_BROWSER_NAVIGATOR_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/ref_counted.h"
11 #include "base/memory/ref_counted_memory.h"
10 #include "chrome/browser/ui/host_desktop.h" 12 #include "chrome/browser/ui/host_desktop.h"
11 #include "content/public/browser/browser_context.h" 13 #include "content/public/browser/browser_context.h"
12 #include "content/public/browser/global_request_id.h" 14 #include "content/public/browser/global_request_id.h"
13 #include "content/public/browser/page_navigator.h" 15 #include "content/public/browser/page_navigator.h"
14 #include "content/public/common/page_transition_types.h" 16 #include "content/public/common/page_transition_types.h"
15 #include "content/public/common/referrer.h" 17 #include "content/public/common/referrer.h"
16 #include "ui/base/window_open_disposition.h" 18 #include "ui/base/window_open_disposition.h"
17 #include "ui/gfx/rect.h" 19 #include "ui/gfx/rect.h"
18 #include "url/gurl.h" 20 #include "url/gurl.h"
19 21
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 content::WebContents* a_target_contents); 58 content::WebContents* a_target_contents);
57 NavigateParams(Profile* profile, 59 NavigateParams(Profile* profile,
58 const GURL& a_url, 60 const GURL& a_url,
59 content::PageTransition a_transition); 61 content::PageTransition a_transition);
60 ~NavigateParams(); 62 ~NavigateParams();
61 63
62 // The URL/referrer to be loaded. Ignored if |target_contents| is non-NULL. 64 // The URL/referrer to be loaded. Ignored if |target_contents| is non-NULL.
63 GURL url; 65 GURL url;
64 content::Referrer referrer; 66 content::Referrer referrer;
65 67
68 // Indicates whether this navigation will be sent using POST.
69 // The POST method is limited support for basic POST data by leveraging
70 // NavigationController::LOAD_TYPE_BROWSER_INITIATED_HTTP_POST.
71 // It is not for things like file uploads.
72 bool uses_post;
73
74 // The post data when the navigation uses POST.
75 scoped_refptr<base::RefCountedMemory> browser_initiated_post_data;
76
66 // Extra headers to add to the request for this page. Headers are 77 // Extra headers to add to the request for this page. Headers are
67 // represented as "<name>: <value>" and separated by \r\n. The entire string 78 // represented as "<name>: <value>" and separated by \r\n. The entire string
68 // is terminated by \r\n. May be empty if no extra headers are needed. 79 // is terminated by \r\n. May be empty if no extra headers are needed.
69 std::string extra_headers; 80 std::string extra_headers;
70 81
71 // [in] A WebContents to be navigated or inserted into the target 82 // [in] A WebContents to be navigated or inserted into the target
72 // Browser's tabstrip. If NULL, |url| or the homepage will be used 83 // Browser's tabstrip. If NULL, |url| or the homepage will be used
73 // instead. When non-NULL, Navigate() assumes it has already been 84 // instead. When non-NULL, Navigate() assumes it has already been
74 // navigated to its intended destination and will not load any URL in it 85 // navigated to its intended destination and will not load any URL in it
75 // (i.e. |url| is ignored). 86 // (i.e. |url| is ignored).
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
227 // Navigates according to the configuration specified in |params|. 238 // Navigates according to the configuration specified in |params|.
228 void Navigate(NavigateParams* params); 239 void Navigate(NavigateParams* params);
229 240
230 // Returns true if the url is allowed to open in incognito window. 241 // Returns true if the url is allowed to open in incognito window.
231 bool IsURLAllowedInIncognito(const GURL& url, 242 bool IsURLAllowedInIncognito(const GURL& url,
232 content::BrowserContext* browser_context); 243 content::BrowserContext* browser_context);
233 244
234 } // namespace chrome 245 } // namespace chrome
235 246
236 #endif // CHROME_BROWSER_UI_BROWSER_NAVIGATOR_H_ 247 #endif // CHROME_BROWSER_UI_BROWSER_NAVIGATOR_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/browser_navigator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698