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

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

Issue 2465803002: Get rid of VisibleSelection::expandUsingGranularity() (Closed)
Patch Set: 2016-10-31T17:16:07 Created 4 years, 1 month 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 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 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 bool isNonOrphanedCaretOrRange() const { 115 bool isNonOrphanedCaretOrRange() const {
116 return !isNone() && !start().isOrphan() && !end().isOrphan(); 116 return !isNone() && !start().isOrphan() && !end().isOrphan();
117 } 117 }
118 118
119 bool isBaseFirst() const { return m_baseIsFirst; } 119 bool isBaseFirst() const { return m_baseIsFirst; }
120 bool isDirectional() const { return m_isDirectional; } 120 bool isDirectional() const { return m_isDirectional; }
121 void setIsDirectional(bool isDirectional) { m_isDirectional = isDirectional; } 121 void setIsDirectional(bool isDirectional) { m_isDirectional = isDirectional; }
122 122
123 void appendTrailingWhitespace(); 123 void appendTrailingWhitespace();
124 124
125 void expandUsingGranularity(TextGranularity);
126
127 // TODO(yosin) Most callers probably don't want these functions, but 125 // TODO(yosin) Most callers probably don't want these functions, but
128 // are using them for historical reasons. |toNormalizedEphemeralRange()| 126 // are using them for historical reasons. |toNormalizedEphemeralRange()|
129 // contracts the range around text, and moves the caret most backward 127 // contracts the range around text, and moves the caret most backward
130 // visually equivalent position before returning the range/positions. 128 // visually equivalent position before returning the range/positions.
131 EphemeralRangeTemplate<Strategy> toNormalizedEphemeralRange() const; 129 EphemeralRangeTemplate<Strategy> toNormalizedEphemeralRange() const;
132 130
133 Element* rootEditableElement() const; 131 Element* rootEditableElement() const;
134 bool isContentEditable() const; 132 bool isContentEditable() const;
135 bool hasEditableStyle() const; 133 bool hasEditableStyle() const;
136 bool isContentRichlyEditable() const; 134 bool isContentRichlyEditable() const;
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
225 223
226 #ifndef NDEBUG 224 #ifndef NDEBUG
227 // Outside the WebCore namespace for ease of invocation from gdb. 225 // Outside the WebCore namespace for ease of invocation from gdb.
228 void showTree(const blink::VisibleSelection&); 226 void showTree(const blink::VisibleSelection&);
229 void showTree(const blink::VisibleSelection*); 227 void showTree(const blink::VisibleSelection*);
230 void showTree(const blink::VisibleSelectionInFlatTree&); 228 void showTree(const blink::VisibleSelectionInFlatTree&);
231 void showTree(const blink::VisibleSelectionInFlatTree*); 229 void showTree(const blink::VisibleSelectionInFlatTree*);
232 #endif 230 #endif
233 231
234 #endif // VisibleSelection_h 232 #endif // VisibleSelection_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698