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 261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
272 ContainerNode::setActive(down, pause); | 272 ContainerNode::setActive(down, pause); |
273 } | 273 } |
274 | 274 |
275 void HTMLAnchorElement::parseAttribute(const QualifiedName& name, const AtomicSt
ring& value) | 275 void HTMLAnchorElement::parseAttribute(const QualifiedName& name, const AtomicSt
ring& value) |
276 { | 276 { |
277 if (name == hrefAttr) { | 277 if (name == hrefAttr) { |
278 bool wasLink = isLink(); | 278 bool wasLink = isLink(); |
279 setIsLink(!value.isNull()); | 279 setIsLink(!value.isNull()); |
280 if (wasLink != isLink()) { | 280 if (wasLink != isLink()) { |
281 didAffectSelector(AffectedSelectorLink | AffectedSelectorVisited | A
ffectedSelectorEnabled); | 281 didAffectSelector(AffectedSelectorLink | AffectedSelectorVisited | A
ffectedSelectorEnabled); |
282 if (wasLink && treeScope().adjustedFocusedElement() == this) { | 282 if (wasLink && treeScope()->adjustedFocusedElement() == this) { |
283 // We might want to call blur(), but it's dangerous to dispatch | 283 // We might want to call blur(), but it's dangerous to dispatch |
284 // events here. | 284 // events here. |
285 document().setNeedsFocusedElementCheck(); | 285 document().setNeedsFocusedElementCheck(); |
286 } | 286 } |
287 } | 287 } |
288 if (isLink()) { | 288 if (isLink()) { |
289 String parsedURL = stripLeadingAndTrailingHTMLSpaces(value); | 289 String parsedURL = stripLeadingAndTrailingHTMLSpaces(value); |
290 if (document().isDNSPrefetchEnabled()) { | 290 if (document().isDNSPrefetchEnabled()) { |
291 if (protocolIs(parsedURL, "http") || protocolIs(parsedURL, "http
s") || parsedURL.startsWith("//")) | 291 if (protocolIs(parsedURL, "http") || protocolIs(parsedURL, "http
s") || parsedURL.startsWith("//")) |
292 prefetchDNS(document().completeURL(parsedURL).host()); | 292 prefetchDNS(document().completeURL(parsedURL).host()); |
(...skipping 551 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
844 | 844 |
845 // The precision of current MouseOver trigger is too low to actually trigger
preconnects. | 845 // The precision of current MouseOver trigger is too low to actually trigger
preconnects. |
846 if (motivation == WebKit::WebPreconnectMotivationLinkMouseOver) | 846 if (motivation == WebKit::WebPreconnectMotivationLinkMouseOver) |
847 return; | 847 return; |
848 | 848 |
849 preconnectToURL(url, motivation); | 849 preconnectToURL(url, motivation); |
850 m_hasIssuedPreconnect = true; | 850 m_hasIssuedPreconnect = true; |
851 } | 851 } |
852 | 852 |
853 } | 853 } |
OLD | NEW |