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

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

Issue 1675163002: Rename ComposedTree to FlatTree (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: wip Created 4 years, 10 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 /* 1 /*
2 * Copyright (C) 2004, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 void showTreeForThis() const; 104 void showTreeForThis() const;
105 #endif 105 #endif
106 106
107 private: 107 private:
108 explicit VisiblePositionTemplate(const PositionWithAffinityTemplate<Strategy >&); 108 explicit VisiblePositionTemplate(const PositionWithAffinityTemplate<Strategy >&);
109 109
110 PositionWithAffinityTemplate<Strategy> m_positionWithAffinity; 110 PositionWithAffinityTemplate<Strategy> m_positionWithAffinity;
111 }; 111 };
112 112
113 extern template class CORE_EXTERN_TEMPLATE_EXPORT VisiblePositionTemplate<Editin gStrategy>; 113 extern template class CORE_EXTERN_TEMPLATE_EXPORT VisiblePositionTemplate<Editin gStrategy>;
114 extern template class CORE_EXTERN_TEMPLATE_EXPORT VisiblePositionTemplate<Editin gInComposedTreeStrategy>; 114 extern template class CORE_EXTERN_TEMPLATE_EXPORT VisiblePositionTemplate<Editin gInFlatTreeStrategy>;
115 115
116 using VisiblePosition = VisiblePositionTemplate<EditingStrategy>; 116 using VisiblePosition = VisiblePositionTemplate<EditingStrategy>;
117 using VisiblePositionInComposedTree = VisiblePositionTemplate<EditingInComposedT reeStrategy>; 117 using VisiblePositionInFlatTree = VisiblePositionTemplate<EditingInFlatTreeStrat egy>;
118 118
119 CORE_EXPORT VisiblePosition createVisiblePosition(const Position&, TextAffinity = VP_DEFAULT_AFFINITY); 119 CORE_EXPORT VisiblePosition createVisiblePosition(const Position&, TextAffinity = VP_DEFAULT_AFFINITY);
120 CORE_EXPORT VisiblePosition createVisiblePosition(const PositionWithAffinity&); 120 CORE_EXPORT VisiblePosition createVisiblePosition(const PositionWithAffinity&);
121 CORE_EXPORT VisiblePositionInComposedTree createVisiblePosition(const PositionIn ComposedTree&, TextAffinity = VP_DEFAULT_AFFINITY); 121 CORE_EXPORT VisiblePositionInFlatTree createVisiblePosition(const PositionInFlat Tree&, TextAffinity = VP_DEFAULT_AFFINITY);
122 CORE_EXPORT VisiblePositionInComposedTree createVisiblePosition(const PositionIn ComposedTreeWithAffinity&); 122 CORE_EXPORT VisiblePositionInFlatTree createVisiblePosition(const PositionInFlat TreeWithAffinity&);
123 123
124 // TODO(yosin) Once we have composed tree version of VisibleUnits, we should not 124 // TODO(yosin) Once we have flat tree version of VisibleUnits, we should not
125 // use |createVisiblePositionInDOMTree()|. 125 // use |createVisiblePositionInDOMTree()|.
126 VisiblePosition createVisiblePositionInDOMTree(const Position&, TextAffinity = V P_DEFAULT_AFFINITY); 126 VisiblePosition createVisiblePositionInDOMTree(const Position&, TextAffinity = V P_DEFAULT_AFFINITY);
127 VisiblePosition createVisiblePositionInDOMTree(const PositionInComposedTree&, Te xtAffinity = VP_DEFAULT_AFFINITY); 127 VisiblePosition createVisiblePositionInDOMTree(const PositionInFlatTree&, TextAf finity = VP_DEFAULT_AFFINITY);
128 128
129 } // namespace blink 129 } // namespace blink
130 130
131 #ifndef NDEBUG 131 #ifndef NDEBUG
132 // Outside the WebCore namespace for ease of invocation from gdb. 132 // Outside the WebCore namespace for ease of invocation from gdb.
133 void showTree(const blink::VisiblePosition*); 133 void showTree(const blink::VisiblePosition*);
134 void showTree(const blink::VisiblePosition&); 134 void showTree(const blink::VisiblePosition&);
135 #endif 135 #endif
136 136
137 #endif // VisiblePosition_h 137 #endif // VisiblePosition_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698