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

Side by Side Diff: third_party/WebKit/Source/modules/fetch/FetchManager.cpp

Issue 1738613002: Rename enums/functions that collide in chromium style in core/dom/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@get-names-3
Patch Set: get-names-4: Created 4 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "modules/fetch/FetchManager.h" 5 #include "modules/fetch/FetchManager.h"
6 6
7 #include "bindings/core/v8/ExceptionState.h" 7 #include "bindings/core/v8/ExceptionState.h"
8 #include "bindings/core/v8/ScriptPromiseResolver.h" 8 #include "bindings/core/v8/ScriptPromiseResolver.h"
9 #include "bindings/core/v8/ScriptState.h" 9 #include "bindings/core/v8/ScriptState.h"
10 #include "bindings/core/v8/V8ThrowException.h" 10 #include "bindings/core/v8/V8ThrowException.h"
(...skipping 532 matching lines...) Expand 10 before | Expand all | Expand 10 after
543 543
544 // "2. Append `Referer`/empty byte sequence, if |HTTPRequest|'s |referrer| 544 // "2. Append `Referer`/empty byte sequence, if |HTTPRequest|'s |referrer|
545 // is none, and `Referer`/|HTTPRequest|'s referrer, serialized and utf-8 545 // is none, and `Referer`/|HTTPRequest|'s referrer, serialized and utf-8
546 // encoded, otherwise, to HTTPRequest's header list. 546 // encoded, otherwise, to HTTPRequest's header list.
547 // 547 //
548 // The following code also invokes "determine request's referrer" which is 548 // The following code also invokes "determine request's referrer" which is
549 // written in "Main fetch" operation. 549 // written in "Main fetch" operation.
550 ASSERT(m_request->referrerPolicy() == ReferrerPolicyDefault); 550 ASSERT(m_request->referrerPolicy() == ReferrerPolicyDefault);
551 // Request's referrer policy is always default, so use the client's one. 551 // Request's referrer policy is always default, so use the client's one.
552 // TODO(yhirano): Fix here when we introduce requet's referrer policy. 552 // TODO(yhirano): Fix here when we introduce requet's referrer policy.
553 ReferrerPolicy policy = executionContext()->referrerPolicy(); 553 ReferrerPolicy policy = executionContext()->getReferrerPolicy();
554 if (m_request->referrerString() == FetchRequestData::clientReferrerString()) { 554 if (m_request->referrerString() == FetchRequestData::clientReferrerString()) {
555 String referrerURL; 555 String referrerURL;
556 if (executionContext()->isDocument()) { 556 if (executionContext()->isDocument()) {
557 Document* document = toDocument(executionContext()); 557 Document* document = toDocument(executionContext());
558 referrerURL = document->outgoingReferrer(); 558 referrerURL = document->outgoingReferrer();
559 } else if (executionContext()->isWorkerGlobalScope()) { 559 } else if (executionContext()->isWorkerGlobalScope()) {
560 referrerURL = executionContext()->url().strippedForUseAsReferrer(); 560 referrerURL = executionContext()->url().strippedForUseAsReferrer();
561 } 561 }
562 request.setHTTPReferrer(SecurityPolicy::generateReferrer(policy, m_reque st->url(), referrerURL)); 562 request.setHTTPReferrer(SecurityPolicy::generateReferrer(policy, m_reque st->url(), referrerURL));
563 } else { 563 } else {
(...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after
714 loader->dispose(); 714 loader->dispose();
715 } 715 }
716 716
717 DEFINE_TRACE(FetchManager) 717 DEFINE_TRACE(FetchManager)
718 { 718 {
719 visitor->trace(m_executionContext); 719 visitor->trace(m_executionContext);
720 visitor->trace(m_loaders); 720 visitor->trace(m_loaders);
721 } 721 }
722 722
723 } // namespace blink 723 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698