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

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

Issue 2780313002: [WIP] Refactor DocumentMarker (Closed)
Patch Set: Move CompositionMarkerList::at() into this CL Created 3 years, 8 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
(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 SpellCheckMarker_h
6 #define SpellCheckMarker_h
7
8 #include "core/editing/markers/DocumentMarker.h"
9
10 namespace blink {
11
12 class CORE_EXPORT SpellCheckMarker final : public DocumentMarker {
13 public:
14 SpellCheckMarker(DocumentMarker::MarkerType,
15 unsigned startOffset,
16 unsigned endOffset,
17 const String& description);
18
19 // DocumentMarker implementations
20 SpellCheckMarker* clone() const final;
21
22 MarkerType type() const final;
23
24 const String& description() const final;
25
26 protected:
27 SpellCheckMarker(const SpellCheckMarker&) = default;
28
29 private:
30 DocumentMarker::MarkerType m_type;
31 String m_description;
32 };
33
34 DEFINE_TYPE_CASTS(SpellCheckMarker,
35 DocumentMarker,
36 marker,
37 marker->type() == DocumentMarker::Spelling ||
38 marker->type() == DocumentMarker::Grammar,
39 marker.type() == DocumentMarker::Spelling ||
40 marker.type() == DocumentMarker::Grammar);
41
42 } // namespace blink
43
44 #endif // SpellCheckMarker_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698