OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 SelectionTemplate_h | 5 #ifndef SelectionTemplate_h |
6 #define SelectionTemplate_h | 6 #define SelectionTemplate_h |
7 | 7 |
8 #include <iosfwd> | 8 #include <iosfwd> |
9 #include "base/macros.h" | 9 #include "base/macros.h" |
10 #include "core/CoreExport.h" | 10 #include "core/CoreExport.h" |
11 #include "core/editing/EphemeralRange.h" | 11 #include "core/editing/EphemeralRange.h" |
12 #include "core/editing/Position.h" | 12 #include "core/editing/Position.h" |
13 #include "core/editing/PositionWithAffinity.h" | 13 #include "core/editing/PositionWithAffinity.h" |
14 #include "core/editing/SelectionType.h" | 14 #include "core/editing/SelectionType.h" |
15 #include "core/editing/TextAffinity.h" | 15 #include "core/editing/TextAffinity.h" |
16 #include "core/editing/TextGranularity.h" | 16 #include "core/editing/TextGranularity.h" |
17 #include "wtf/Allocator.h" | 17 #include "platform/wtf/Allocator.h" |
18 | 18 |
19 namespace blink { | 19 namespace blink { |
20 | 20 |
21 // SelectionTemplate is used for representing a selection in DOM tree or Flat | 21 // SelectionTemplate is used for representing a selection in DOM tree or Flat |
22 // tree with template parameter |Strategy|. Instances of |SelectionTemplate| | 22 // tree with template parameter |Strategy|. Instances of |SelectionTemplate| |
23 // are immutable objects, you can't change them once constructed. | 23 // are immutable objects, you can't change them once constructed. |
24 // | 24 // |
25 // To construct |SelectionTemplate| object, please use |Builder| class. | 25 // To construct |SelectionTemplate| object, please use |Builder| class. |
26 template <typename Strategy> | 26 template <typename Strategy> |
27 class CORE_EXPORT SelectionTemplate final { | 27 class CORE_EXPORT SelectionTemplate final { |
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
140 | 140 |
141 using SelectionInDOMTree = SelectionTemplate<EditingStrategy>; | 141 using SelectionInDOMTree = SelectionTemplate<EditingStrategy>; |
142 using SelectionInFlatTree = SelectionTemplate<EditingInFlatTreeStrategy>; | 142 using SelectionInFlatTree = SelectionTemplate<EditingInFlatTreeStrategy>; |
143 | 143 |
144 CORE_EXPORT std::ostream& operator<<(std::ostream&, const SelectionInDOMTree&); | 144 CORE_EXPORT std::ostream& operator<<(std::ostream&, const SelectionInDOMTree&); |
145 CORE_EXPORT std::ostream& operator<<(std::ostream&, const SelectionInFlatTree&); | 145 CORE_EXPORT std::ostream& operator<<(std::ostream&, const SelectionInFlatTree&); |
146 | 146 |
147 } // namespace blink | 147 } // namespace blink |
148 | 148 |
149 #endif // SelectionTemplate_h | 149 #endif // SelectionTemplate_h |
OLD | NEW |