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

Side by Side Diff: Source/core/editing/Position.h

Issue 1298823003: Move isRenderedCharacter() to EditorCommand.cpp from Position.cpp (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 2015-08-20T14:16:30 Rebase Created 5 years, 4 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 | Source/core/editing/Position.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, 2006, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2006, 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 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
236 int m_offset; 236 int m_offset;
237 PositionAnchorType m_anchorType; 237 PositionAnchorType m_anchorType;
238 }; 238 };
239 239
240 extern template class CORE_EXTERN_TEMPLATE_EXPORT PositionAlgorithm<EditingStrat egy>; 240 extern template class CORE_EXTERN_TEMPLATE_EXPORT PositionAlgorithm<EditingStrat egy>;
241 extern template class CORE_EXTERN_TEMPLATE_EXPORT PositionAlgorithm<EditingInCom posedTreeStrategy>; 241 extern template class CORE_EXTERN_TEMPLATE_EXPORT PositionAlgorithm<EditingInCom posedTreeStrategy>;
242 242
243 using Position = PositionAlgorithm<EditingStrategy>; 243 using Position = PositionAlgorithm<EditingStrategy>;
244 using PositionInComposedTree = PositionAlgorithm<EditingInComposedTreeStrategy>; 244 using PositionInComposedTree = PositionAlgorithm<EditingInComposedTreeStrategy>;
245 245
246 // TODO(yosin) |isRenderedCharacter()| should be removed, and we should use
247 // |VisiblePosition::characterAfter()| and |VisiblePosition::characterBefore()|.
248 // TODO(yosin) We should move |isRenderedCharacter()| to "VisibleUnits.cpp",
249 // since it is used only in "editing/commands/"
250 CORE_EXPORT bool isRenderedCharacter(const Position&);
251
252 // TODO(yosin) We should make |parentEditingBoundary()| as static function 246 // TODO(yosin) We should make |parentEditingBoundary()| as static function
253 // in "VisibleUnits.cpp", since it is used only there. 247 // in "VisibleUnits.cpp", since it is used only there.
254 CORE_EXPORT Node* parentEditingBoundary(const Position&); 248 CORE_EXPORT Node* parentEditingBoundary(const Position&);
255 CORE_EXPORT Node* parentEditingBoundary(const PositionInComposedTree&); 249 CORE_EXPORT Node* parentEditingBoundary(const PositionInComposedTree&);
256 250
257 template <typename Strategy> 251 template <typename Strategy>
258 bool operator==(const PositionAlgorithm<Strategy>& a, const PositionAlgorithm<St rategy>& b) 252 bool operator==(const PositionAlgorithm<Strategy>& a, const PositionAlgorithm<St rategy>& b)
259 { 253 {
260 if (a.isNull()) 254 if (a.isNull())
261 return b.isNull(); 255 return b.isNull();
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
450 444
451 } // namespace blink 445 } // namespace blink
452 446
453 #ifndef NDEBUG 447 #ifndef NDEBUG
454 // Outside the WebCore namespace for ease of invocation from gdb. 448 // Outside the WebCore namespace for ease of invocation from gdb.
455 void showTree(const blink::Position&); 449 void showTree(const blink::Position&);
456 void showTree(const blink::Position*); 450 void showTree(const blink::Position*);
457 #endif 451 #endif
458 452
459 #endif // Position_h 453 #endif // Position_h
OLDNEW
« no previous file with comments | « no previous file | Source/core/editing/Position.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698