| OLD | NEW |
| 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 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 const PositionTemplate<Strategy>& b); | 64 const PositionTemplate<Strategy>& b); |
| 65 static PositionTemplate<Strategy> editingPositionOf(Node* anchorNode, | 65 static PositionTemplate<Strategy> editingPositionOf(Node* anchorNode, |
| 66 int offset); | 66 int offset); |
| 67 | 67 |
| 68 // For creating before/after positions: | 68 // For creating before/after positions: |
| 69 PositionTemplate(Node* anchorNode, PositionAnchorType); | 69 PositionTemplate(Node* anchorNode, PositionAnchorType); |
| 70 | 70 |
| 71 // For creating offset positions: | 71 // For creating offset positions: |
| 72 // FIXME: This constructor should eventually go away. See bug 63040. | 72 // FIXME: This constructor should eventually go away. See bug 63040. |
| 73 PositionTemplate(Node* anchorNode, int offset); | 73 PositionTemplate(Node* anchorNode, int offset); |
| 74 PositionTemplate(const Node& anchorNode, int offset); |
| 74 | 75 |
| 75 PositionTemplate(const PositionTemplate&); | 76 PositionTemplate(const PositionTemplate&); |
| 76 | 77 |
| 77 PositionAnchorType anchorType() const { return m_anchorType; } | 78 PositionAnchorType anchorType() const { return m_anchorType; } |
| 78 bool isAfterAnchor() const { | 79 bool isAfterAnchor() const { |
| 79 return m_anchorType == PositionAnchorType::AfterAnchor; | 80 return m_anchorType == PositionAnchorType::AfterAnchor; |
| 80 } | 81 } |
| 81 bool isAfterChildren() const { | 82 bool isAfterChildren() const { |
| 82 return m_anchorType == PositionAnchorType::AfterChildren; | 83 return m_anchorType == PositionAnchorType::AfterChildren; |
| 83 } | 84 } |
| (...skipping 190 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 274 | 275 |
| 275 } // namespace blink | 276 } // namespace blink |
| 276 | 277 |
| 277 #ifndef NDEBUG | 278 #ifndef NDEBUG |
| 278 // Outside the WebCore namespace for ease of invocation from gdb. | 279 // Outside the WebCore namespace for ease of invocation from gdb. |
| 279 void showTree(const blink::Position&); | 280 void showTree(const blink::Position&); |
| 280 void showTree(const blink::Position*); | 281 void showTree(const blink::Position*); |
| 281 #endif | 282 #endif |
| 282 | 283 |
| 283 #endif // Position_h | 284 #endif // Position_h |
| OLD | NEW |