OLD | NEW |
(Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CompositionMarkerList_h |
| 6 #define CompositionMarkerList_h |
| 7 |
| 8 #include "core/editing/markers/DocumentMarkerList.h" |
| 9 |
| 10 namespace blink { |
| 11 |
| 12 class CORE_EXPORT CompositionMarkerList final : public DocumentMarkerList { |
| 13 public: |
| 14 CompositionMarkerList(); |
| 15 |
| 16 DocumentMarker::MarkerType allowedMarkerType() const final; |
| 17 |
| 18 bool empty() const final; |
| 19 DocumentMarker* at(size_t index) final; |
| 20 |
| 21 void add(DocumentMarker*) final; |
| 22 void clear() final; |
| 23 |
| 24 void appendMarkersToInputList(DocumentMarkerVector* list) const; |
| 25 |
| 26 DidCopyMarkerOrNot copyMarkers(unsigned startOffset, |
| 27 int length, |
| 28 DocumentMarkerList* dstList, |
| 29 int delta) final; |
| 30 |
| 31 DidRemoveMarkerOrNot removeMarkers( |
| 32 unsigned startOffset, |
| 33 int length, |
| 34 bool shouldRemovePartiallyOverlappingMarkers) final; |
| 35 |
| 36 DidShiftMarkerOrNot shiftMarkers(unsigned offset, |
| 37 unsigned oldLength, |
| 38 unsigned newLength) final; |
| 39 |
| 40 DECLARE_VIRTUAL_TRACE(); |
| 41 |
| 42 private: |
| 43 HeapVector<Member<DocumentMarker>> m_markers; |
| 44 |
| 45 DISALLOW_COPY_AND_ASSIGN(CompositionMarkerList); |
| 46 }; |
| 47 |
| 48 DEFINE_TYPE_CASTS(CompositionMarkerList, |
| 49 DocumentMarkerList, |
| 50 list, |
| 51 list->allowedMarkerType() == DocumentMarker::Composition, |
| 52 list.allowedMarkerType() == DocumentMarker::Composition); |
| 53 |
| 54 } // namespace blink |
| 55 |
| 56 #endif // CompositionMarkerList_h |
OLD | NEW |