OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2000 Simon Hausmann <hausmann@kde.org> | 4 * (C) 2000 Simon Hausmann <hausmann@kde.org> |
5 * Copyright (C) 2003, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. | 5 * Copyright (C) 2003, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. |
6 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) | 6 * (C) 2006 Graham Dennis (graham.dennis@gmail.com) |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
336 request.setUIStartTime(event->platformTimeStamp()); | 336 request.setUIStartTime(event->platformTimeStamp()); |
337 request.setInputPerfMetricReportPolicy(InputToLoadPerfMetricReportPolicy::Re
portLink); | 337 request.setInputPerfMetricReportPolicy(InputToLoadPerfMetricReportPolicy::Re
portLink); |
338 | 338 |
339 ReferrerPolicy policy; | 339 ReferrerPolicy policy; |
340 if (hasAttribute(referrerpolicyAttr) && SecurityPolicy::referrerPolicyFromSt
ring(fastGetAttribute(referrerpolicyAttr), &policy) && !hasRel(RelationNoReferre
r)) { | 340 if (hasAttribute(referrerpolicyAttr) && SecurityPolicy::referrerPolicyFromSt
ring(fastGetAttribute(referrerpolicyAttr), &policy) && !hasRel(RelationNoReferre
r)) { |
341 request.setHTTPReferrer(SecurityPolicy::generateReferrer(policy, complet
edURL, document().outgoingReferrer())); | 341 request.setHTTPReferrer(SecurityPolicy::generateReferrer(policy, complet
edURL, document().outgoingReferrer())); |
342 } | 342 } |
343 | 343 |
344 if (hasAttribute(downloadAttr)) { | 344 if (hasAttribute(downloadAttr)) { |
345 request.setRequestContext(WebURLRequest::RequestContextDownload); | 345 request.setRequestContext(WebURLRequest::RequestContextDownload); |
346 bool isSameOrigin = completedURL.protocolIsData() || document().security
Origin()->canRequest(completedURL); | 346 bool isSameOrigin = completedURL.protocolIsData() || document().getSecur
ityOrigin()->canRequest(completedURL); |
347 const AtomicString& suggestedName = (isSameOrigin ? fastGetAttribute(dow
nloadAttr) : nullAtom); | 347 const AtomicString& suggestedName = (isSameOrigin ? fastGetAttribute(dow
nloadAttr) : nullAtom); |
348 | 348 |
349 frame->loader().client()->loadURLExternally(request, NavigationPolicyDow
nload, suggestedName, false); | 349 frame->loader().client()->loadURLExternally(request, NavigationPolicyDow
nload, suggestedName, false); |
350 } else { | 350 } else { |
351 request.setRequestContext(WebURLRequest::RequestContextHyperlink); | 351 request.setRequestContext(WebURLRequest::RequestContextHyperlink); |
352 FrameLoadRequest frameRequest(&document(), request, getAttribute(targetA
ttr)); | 352 FrameLoadRequest frameRequest(&document(), request, getAttribute(targetA
ttr)); |
353 frameRequest.setTriggeringEvent(event); | 353 frameRequest.setTriggeringEvent(event); |
354 if (hasRel(RelationNoReferrer)) { | 354 if (hasRel(RelationNoReferrer)) { |
355 frameRequest.setShouldSendReferrer(NeverSendReferrer); | 355 frameRequest.setShouldSendReferrer(NeverSendReferrer); |
356 frameRequest.setShouldSetOpener(NeverSetOpener); | 356 frameRequest.setShouldSetOpener(NeverSetOpener); |
(...skipping 25 matching lines...) Expand all Loading... |
382 } | 382 } |
383 | 383 |
384 Node::InsertionNotificationRequest HTMLAnchorElement::insertedInto(ContainerNode
* insertionPoint) | 384 Node::InsertionNotificationRequest HTMLAnchorElement::insertedInto(ContainerNode
* insertionPoint) |
385 { | 385 { |
386 InsertionNotificationRequest request = HTMLElement::insertedInto(insertionPo
int); | 386 InsertionNotificationRequest request = HTMLElement::insertedInto(insertionPo
int); |
387 logAddElementIfIsolatedWorldAndInDocument("a", hrefAttr); | 387 logAddElementIfIsolatedWorldAndInDocument("a", hrefAttr); |
388 return request; | 388 return request; |
389 } | 389 } |
390 | 390 |
391 } // namespace blink | 391 } // namespace blink |
OLD | NEW |