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

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

Issue 2952973002: Introduce VisibleSelection::CreateWithoutValidationDeprecated() (Closed)
Patch Set: 2017-06-23T09:54:35 Created 3 years, 5 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
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/editing/VisibleSelection.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004 Apple Computer, Inc. All rights reserved. 2 * Copyright (C) 2004 Apple Computer, 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 107 matching lines...) Expand 10 before | Expand all | Expand 10 after
118 // contracts the range around text, and moves the caret most backward 118 // contracts the range around text, and moves the caret most backward
119 // visually equivalent position before returning the range/positions. 119 // visually equivalent position before returning the range/positions.
120 EphemeralRangeTemplate<Strategy> ToNormalizedEphemeralRange() const; 120 EphemeralRangeTemplate<Strategy> ToNormalizedEphemeralRange() const;
121 121
122 Element* RootEditableElement() const; 122 Element* RootEditableElement() const;
123 bool IsContentEditable() const; 123 bool IsContentEditable() const;
124 bool HasEditableStyle() const; 124 bool HasEditableStyle() const;
125 bool IsContentRichlyEditable() const; 125 bool IsContentRichlyEditable() const;
126 126
127 bool IsValidFor(const Document&) const; 127 bool IsValidFor(const Document&) const;
128 void SetWithoutValidation(const PositionTemplate<Strategy>&, 128
129 const PositionTemplate<Strategy>&); 129 // TODO(editing-dev): |CreateWithoutValidationDeprecated()| is allowed
130 // only to use in |TypingCommand| to remove part of grapheme cluster.
131 // Note: |base| and |extent| can be disconnect position.
132 static VisibleSelectionTemplate<Strategy> CreateWithoutValidationDeprecated(
133 const PositionTemplate<Strategy>& base,
134 const PositionTemplate<Strategy>& extent,
135 TextAffinity);
130 136
131 DECLARE_TRACE(); 137 DECLARE_TRACE();
132 138
133 #ifndef NDEBUG 139 #ifndef NDEBUG
134 void ShowTreeForThis() const; 140 void ShowTreeForThis() const;
135 #endif 141 #endif
136 static void PrintTo(const VisibleSelectionTemplate&, std::ostream*); 142 static void PrintTo(const VisibleSelectionTemplate&, std::ostream*);
137 143
138 private: 144 private:
139 friend class SelectionAdjuster; 145 friend class SelectionAdjuster;
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 210
205 #ifndef NDEBUG 211 #ifndef NDEBUG
206 // Outside the WebCore namespace for ease of invocation from gdb. 212 // Outside the WebCore namespace for ease of invocation from gdb.
207 void showTree(const blink::VisibleSelection&); 213 void showTree(const blink::VisibleSelection&);
208 void showTree(const blink::VisibleSelection*); 214 void showTree(const blink::VisibleSelection*);
209 void showTree(const blink::VisibleSelectionInFlatTree&); 215 void showTree(const blink::VisibleSelectionInFlatTree&);
210 void showTree(const blink::VisibleSelectionInFlatTree*); 216 void showTree(const blink::VisibleSelectionInFlatTree*);
211 #endif 217 #endif
212 218
213 #endif // VisibleSelection_h 219 #endif // VisibleSelection_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/editing/VisibleSelection.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698