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) 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. | 5 * Copyright (C) 2007, 2008, 2009, 2010 Apple Inc. All rights reserved. |
6 * | 6 * |
7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
48 RelationNoReferrer = 0x00001000, | 48 RelationNoReferrer = 0x00001000, |
49 // RelationPrev = 0x00002000, | 49 // RelationPrev = 0x00002000, |
50 // RelationSearch = 0x00004000, | 50 // RelationSearch = 0x00004000, |
51 // RelationSidebar = 0x00008000, | 51 // RelationSidebar = 0x00008000, |
52 // RelationTag = 0x00010000, | 52 // RelationTag = 0x00010000, |
53 // RelationUp = 0x00020000, | 53 // RelationUp = 0x00020000, |
54 }; | 54 }; |
55 | 55 |
56 class HTMLAnchorElement : public HTMLElement { | 56 class HTMLAnchorElement : public HTMLElement { |
57 public: | 57 public: |
58 static PassRefPtr<HTMLAnchorElement> create(Document*); | 58 static PassRefPtr<HTMLAnchorElement> create(Document&); |
59 static PassRefPtr<HTMLAnchorElement> create(const QualifiedName&, Document*)
; | 59 static PassRefPtr<HTMLAnchorElement> create(const QualifiedName&, Document&)
; |
60 | 60 |
61 virtual ~HTMLAnchorElement(); | 61 virtual ~HTMLAnchorElement(); |
62 | 62 |
63 KURL href() const; | 63 KURL href() const; |
64 void setHref(const AtomicString&); | 64 void setHref(const AtomicString&); |
65 | 65 |
66 const AtomicString& name() const; | 66 const AtomicString& name() const; |
67 | 67 |
68 String hash() const; | 68 String hash() const; |
69 void setHash(const String&); | 69 void setHash(const String&); |
(...skipping 26 matching lines...) Expand all Loading... |
96 | 96 |
97 virtual bool willRespondToMouseClickEvents() OVERRIDE; | 97 virtual bool willRespondToMouseClickEvents() OVERRIDE; |
98 | 98 |
99 bool hasRel(uint32_t relation) const; | 99 bool hasRel(uint32_t relation) const; |
100 void setRel(const String&); | 100 void setRel(const String&); |
101 | 101 |
102 LinkHash visitedLinkHash() const; | 102 LinkHash visitedLinkHash() const; |
103 void invalidateCachedVisitedLinkHash() { m_cachedVisitedLinkHash = 0; } | 103 void invalidateCachedVisitedLinkHash() { m_cachedVisitedLinkHash = 0; } |
104 | 104 |
105 protected: | 105 protected: |
106 HTMLAnchorElement(const QualifiedName&, Document*); | 106 HTMLAnchorElement(const QualifiedName&, Document&); |
107 | 107 |
108 virtual void parseAttribute(const QualifiedName&, const AtomicString&) OVERR
IDE; | 108 virtual void parseAttribute(const QualifiedName&, const AtomicString&) OVERR
IDE; |
109 | 109 |
110 private: | 110 private: |
111 virtual bool supportsFocus() const; | 111 virtual bool supportsFocus() const; |
112 virtual bool isMouseFocusable() const; | 112 virtual bool isMouseFocusable() const; |
113 virtual bool isKeyboardFocusable() const OVERRIDE; | 113 virtual bool isKeyboardFocusable() const OVERRIDE; |
114 virtual void defaultEventHandler(Event*); | 114 virtual void defaultEventHandler(Event*); |
115 virtual void setActive(bool active = true, bool pause = false); | 115 virtual void setActive(bool active = true, bool pause = false); |
116 virtual void accessKeyAction(bool sendMouseEvents); | 116 virtual void accessKeyAction(bool sendMouseEvents); |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
170 | 170 |
171 inline HTMLAnchorElement* toHTMLAnchorElement(Node* node) | 171 inline HTMLAnchorElement* toHTMLAnchorElement(Node* node) |
172 { | 172 { |
173 ASSERT_WITH_SECURITY_IMPLICATION(!node || isHTMLAnchorElement(node)); | 173 ASSERT_WITH_SECURITY_IMPLICATION(!node || isHTMLAnchorElement(node)); |
174 return static_cast<HTMLAnchorElement*>(node); | 174 return static_cast<HTMLAnchorElement*>(node); |
175 } | 175 } |
176 | 176 |
177 } // namespace WebCore | 177 } // namespace WebCore |
178 | 178 |
179 #endif // HTMLAnchorElement_h | 179 #endif // HTMLAnchorElement_h |
OLD | NEW |