Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(164)

Side by Side Diff: third_party/WebKit/Source/core/editing/markers/DocumentMarkerList.h

Issue 2868413002: [DMC #5.55] Add DocumentMarkerList::MarkerType() (Closed)
Patch Set: Fix mistake in comment Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef DocumentMarkerList_h 5 #ifndef DocumentMarkerList_h
6 #define DocumentMarkerList_h 6 #define DocumentMarkerList_h
7 7
8 #include "core/CoreExport.h" 8 #include "core/CoreExport.h"
9 #include "core/editing/markers/DocumentMarker.h"
9 #include "platform/heap/Handle.h" 10 #include "platform/heap/Handle.h"
10 11
11 namespace blink { 12 namespace blink {
12 13
13 class DocumentMarker;
14 class RenderedDocumentMarker; 14 class RenderedDocumentMarker;
15 15
16 // This is an interface implemented by classes that DocumentMarkerController 16 // This is an interface implemented by classes that DocumentMarkerController
17 // uses to store DocumentMarkers. Different implementations can be written 17 // uses to store DocumentMarkers. Different implementations can be written
18 // to handle different MarkerTypes (e.g. to provide more optimized handling of 18 // to handle different MarkerTypes (e.g. to provide more optimized handling of
19 // MarkerTypes with different insertion/retrieval patterns, or to provide 19 // MarkerTypes with different insertion/retrieval patterns, or to provide
20 // different behavior for certain MarkerTypes). 20 // different behavior for certain MarkerTypes).
21 class CORE_EXPORT DocumentMarkerList 21 class CORE_EXPORT DocumentMarkerList
22 : public GarbageCollectedFinalized<DocumentMarkerList> { 22 : public GarbageCollectedFinalized<DocumentMarkerList> {
23 public: 23 public:
24 virtual ~DocumentMarkerList(); 24 virtual ~DocumentMarkerList();
25 25
26 // Returns the single marker type supported by the list implementation.
27 virtual DocumentMarker::MarkerType MarkerType() const = 0;
28
26 virtual bool IsEmpty() const = 0; 29 virtual bool IsEmpty() const = 0;
27 30
28 virtual void Add(DocumentMarker*) = 0; 31 virtual void Add(DocumentMarker*) = 0;
29 virtual void Clear() = 0; 32 virtual void Clear() = 0;
30 33
31 virtual const HeapVector<Member<RenderedDocumentMarker>>& GetMarkers() 34 virtual const HeapVector<Member<RenderedDocumentMarker>>& GetMarkers()
32 const = 0; 35 const = 0;
33 36
34 // Returns true if at least one marker is copied, false otherwise 37 // Returns true if at least one marker is copied, false otherwise
35 virtual bool MoveMarkers(int length, DocumentMarkerList* dst_list) = 0; 38 virtual bool MoveMarkers(int length, DocumentMarkerList* dst_list) = 0;
(...skipping 17 matching lines...) Expand all
53 protected: 56 protected:
54 DocumentMarkerList(); 57 DocumentMarkerList();
55 58
56 private: 59 private:
57 DISALLOW_COPY_AND_ASSIGN(DocumentMarkerList); 60 DISALLOW_COPY_AND_ASSIGN(DocumentMarkerList);
58 }; 61 };
59 62
60 } // namespace blink 63 } // namespace blink
61 64
62 #endif // DocumentMarkerList_h 65 #endif // DocumentMarkerList_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698