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) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights
reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights
reserved. |
7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
8 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 8 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
84 void shiftMarkers(Node*, unsigned startOffset, int delta); | 84 void shiftMarkers(Node*, unsigned startOffset, int delta); |
85 void setMarkersActive(Range*, bool); | 85 void setMarkersActive(Range*, bool); |
86 void setMarkersActive(Node*, unsigned startOffset, unsigned endOffset, bool)
; | 86 void setMarkersActive(Node*, unsigned startOffset, unsigned endOffset, bool)
; |
87 | 87 |
88 DocumentMarker* markerContainingPoint(const LayoutPoint&, DocumentMarker::Ma
rkerType); | 88 DocumentMarker* markerContainingPoint(const LayoutPoint&, DocumentMarker::Ma
rkerType); |
89 DocumentMarkerVector markersFor(Node*, DocumentMarker::MarkerTypes = Documen
tMarker::AllMarkers()); | 89 DocumentMarkerVector markersFor(Node*, DocumentMarker::MarkerTypes = Documen
tMarker::AllMarkers()); |
90 DocumentMarkerVector markersInRange(Range*, DocumentMarker::MarkerTypes); | 90 DocumentMarkerVector markersInRange(Range*, DocumentMarker::MarkerTypes); |
91 DocumentMarkerVector markers(); | 91 DocumentMarkerVector markers(); |
92 Vector<IntRect> renderedRectsForMarkers(DocumentMarker::MarkerType); | 92 Vector<IntRect> renderedRectsForMarkers(DocumentMarker::MarkerType); |
93 | 93 |
94 void trace(Visitor*); | 94 DECLARE_TRACE(); |
95 | 95 |
96 #ifndef NDEBUG | 96 #ifndef NDEBUG |
97 void showMarkers() const; | 97 void showMarkers() const; |
98 #endif | 98 #endif |
99 | 99 |
100 private: | 100 private: |
101 void addMarker(Node*, const DocumentMarker&); | 101 void addMarker(Node*, const DocumentMarker&); |
102 | 102 |
103 using MarkerList = WillBeHeapVector<OwnPtrWillBeMember<RenderedDocumentMarke
r>>; | 103 using MarkerList = WillBeHeapVector<OwnPtrWillBeMember<RenderedDocumentMarke
r>>; |
104 using MarkerLists = WillBeHeapVector<OwnPtrWillBeMember<MarkerList>, Documen
tMarker::MarkerTypeIndexesCount>; | 104 using MarkerLists = WillBeHeapVector<OwnPtrWillBeMember<MarkerList>, Documen
tMarker::MarkerTypeIndexesCount>; |
105 using MarkerMap = WillBeHeapHashMap<RawPtrWillBeWeakMember<const Node>, OwnP
trWillBeMember<MarkerLists>>; | 105 using MarkerMap = WillBeHeapHashMap<RawPtrWillBeWeakMember<const Node>, OwnP
trWillBeMember<MarkerLists>>; |
106 void mergeOverlapping(MarkerList*, DocumentMarker&); | 106 void mergeOverlapping(MarkerList*, DocumentMarker&); |
107 bool possiblyHasMarkers(DocumentMarker::MarkerTypes); | 107 bool possiblyHasMarkers(DocumentMarker::MarkerTypes); |
108 void removeMarkersFromList(MarkerMap::iterator, DocumentMarker::MarkerTypes)
; | 108 void removeMarkersFromList(MarkerMap::iterator, DocumentMarker::MarkerTypes)
; |
109 void removeMarkers(TextIterator&, DocumentMarker::MarkerTypes, RemovePartial
lyOverlappingMarkerOrNot); | 109 void removeMarkers(TextIterator&, DocumentMarker::MarkerTypes, RemovePartial
lyOverlappingMarkerOrNot); |
110 | 110 |
111 MarkerMap m_markers; | 111 MarkerMap m_markers; |
112 // Provide a quick way to determine whether a particular marker type is abse
nt without going through the map. | 112 // Provide a quick way to determine whether a particular marker type is abse
nt without going through the map. |
113 DocumentMarker::MarkerTypes m_possiblyExistingMarkerTypes; | 113 DocumentMarker::MarkerTypes m_possiblyExistingMarkerTypes; |
114 }; | 114 }; |
115 | 115 |
116 } // namespace blink | 116 } // namespace blink |
117 | 117 |
118 #ifndef NDEBUG | 118 #ifndef NDEBUG |
119 void showDocumentMarkers(const blink::DocumentMarkerController*); | 119 void showDocumentMarkers(const blink::DocumentMarkerController*); |
120 #endif | 120 #endif |
121 | 121 |
122 #endif // DocumentMarkerController_h | 122 #endif // DocumentMarkerController_h |
OLD | NEW |