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

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

Issue 9726025: Fix bug where we'd allow chrome-extension URLs to be loaded in incognito mode (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: getcurrentdir Created 8 years, 9 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 | « content/browser/renderer_host/resource_request_info_impl.cc ('k') | no next file » | 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 CONTENT_PUBLIC_BROWSER_RESOURCE_REQUEST_INFO_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_RESOURCE_REQUEST_INFO_H_
6 #define CONTENT_PUBLIC_BROWSER_RESOURCE_REQUEST_INFO_H_ 6 #define CONTENT_PUBLIC_BROWSER_RESOURCE_REQUEST_INFO_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "content/common/content_export.h" 10 #include "content/common/content_export.h"
(...skipping 13 matching lines...) Expand all
24 public: 24 public:
25 // Returns the ResourceRequestInfo associated with the given URLRequest. 25 // Returns the ResourceRequestInfo associated with the given URLRequest.
26 CONTENT_EXPORT static const ResourceRequestInfo* ForRequest( 26 CONTENT_EXPORT static const ResourceRequestInfo* ForRequest(
27 const net::URLRequest* request); 27 const net::URLRequest* request);
28 28
29 // Allocates a new, dummy ResourceRequestInfo and associates it with the 29 // Allocates a new, dummy ResourceRequestInfo and associates it with the
30 // given URLRequest. 30 // given URLRequest.
31 // NOTE: Add more parameters if you need to initialize other fields. 31 // NOTE: Add more parameters if you need to initialize other fields.
32 CONTENT_EXPORT static void AllocateForTesting( 32 CONTENT_EXPORT static void AllocateForTesting(
33 net::URLRequest* request, 33 net::URLRequest* request,
34 ResourceType::Type resource_type,
34 ResourceContext* context); 35 ResourceContext* context);
35 36
36 // Returns the associated RenderView for a given process. Returns false, if 37 // Returns the associated RenderView for a given process. Returns false, if
37 // there is no associated RenderView. This method does not rely on the 38 // there is no associated RenderView. This method does not rely on the
38 // request being allocated by the ResourceDispatcherHost, but works for all 39 // request being allocated by the ResourceDispatcherHost, but works for all
39 // URLRequests that are associated with a RenderView. 40 // URLRequests that are associated with a RenderView.
40 CONTENT_EXPORT static bool GetRenderViewForRequest( 41 CONTENT_EXPORT static bool GetRenderViewForRequest(
41 const net::URLRequest* request, 42 const net::URLRequest* request,
42 int* render_process_id, 43 int* render_process_id,
43 int* render_view_id); 44 int* render_view_id);
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 virtual bool GetAssociatedRenderView(int* render_process_id, 87 virtual bool GetAssociatedRenderView(int* render_process_id,
87 int* render_view_id) const = 0; 88 int* render_view_id) const = 0;
88 89
89 protected: 90 protected:
90 virtual ~ResourceRequestInfo() {} 91 virtual ~ResourceRequestInfo() {}
91 }; 92 };
92 93
93 } // namespace content 94 } // namespace content
94 95
95 #endif // CONTENT_PUBLIC_BROWSER_RESOURCE_REQUEST_INFO_H_ 96 #endif // CONTENT_PUBLIC_BROWSER_RESOURCE_REQUEST_INFO_H_
OLDNEW
« no previous file with comments | « content/browser/renderer_host/resource_request_info_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698