| Index: trunk/public/platform/WebURLRequest.h
|
| ===================================================================
|
| --- trunk/public/platform/WebURLRequest.h (revision 179161)
|
| +++ trunk/public/platform/WebURLRequest.h (working copy)
|
| @@ -67,7 +67,30 @@
|
| PriorityVeryHigh,
|
| };
|
|
|
| + enum TargetType {
|
| + TargetIsMainFrame = 0,
|
| + TargetIsSubframe = 1,
|
| + TargetIsSubresource = 2,
|
| + TargetIsStyleSheet = 3,
|
| + TargetIsScript = 4,
|
| + TargetIsFontResource = 5,
|
| + TargetIsImage = 6,
|
| + TargetIsObject = 7,
|
| + TargetIsMedia = 8,
|
| + TargetIsWorker = 9,
|
| + TargetIsSharedWorker = 10,
|
| + TargetIsPrefetch = 11,
|
| + TargetIsFavicon = 12,
|
| + TargetIsXHR = 13,
|
| + TargetIsTextTrack = 14,
|
| + TargetIsPing = 15,
|
| + TargetIsServiceWorker = 16,
|
| + TargetIsUnspecified = 17,
|
| + };
|
| +
|
| // Corresponds to Fetch's "context": http://fetch.spec.whatwg.org/#concept-request-context
|
| + //
|
| + // FIXME: Drop the TargetType enum once embedders are updated upstream.
|
| enum RequestContext {
|
| RequestContextUnspecified = 0,
|
| RequestContextInternal, // FIXME: This isn't part of Fetch. It should be.
|
| @@ -177,6 +200,10 @@
|
| BLINK_PLATFORM_EXPORT bool reportRawHeaders() const;
|
| BLINK_PLATFORM_EXPORT void setReportRawHeaders(bool);
|
|
|
| + // FIXME: Remove these once content/ and net/ are updated.
|
| + BLINK_PLATFORM_EXPORT TargetType targetType() const;
|
| + BLINK_PLATFORM_EXPORT void setTargetType(TargetType);
|
| +
|
| BLINK_PLATFORM_EXPORT RequestContext requestContext() const;
|
| BLINK_PLATFORM_EXPORT void setRequestContext(RequestContext);
|
|
|
| @@ -229,6 +256,10 @@
|
| BLINK_PLATFORM_EXPORT const blink::ResourceRequest& toResourceRequest() const;
|
| #endif
|
|
|
| + // FIXME: Drop these once we replace TargetType upstream.
|
| + static RequestContext requestContextFromTargetType(TargetType);
|
| + static TargetType targetTypeFromRequestContextAndFrameType(RequestContext, FrameType);
|
| +
|
| protected:
|
| BLINK_PLATFORM_EXPORT void assign(WebURLRequestPrivate*);
|
|
|
|
|