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 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 OffsetInAnchor, | 49 OffsetInAnchor, |
50 BeforeAnchor, | 50 BeforeAnchor, |
51 AfterAnchor, | 51 AfterAnchor, |
52 BeforeChildren, | 52 BeforeChildren, |
53 AfterChildren, | 53 AfterChildren, |
54 }; | 54 }; |
55 | 55 |
56 // Instances of |PositionTemplate<Strategy>| are immutable. | 56 // Instances of |PositionTemplate<Strategy>| are immutable. |
57 template <typename Strategy> | 57 template <typename Strategy> |
58 class CORE_TEMPLATE_CLASS_EXPORT PositionTemplate { | 58 class CORE_TEMPLATE_CLASS_EXPORT PositionTemplate { |
59 DISALLOW_ALLOCATION(); | 59 DISALLOW_NEW(); |
60 public: | 60 public: |
61 | 61 |
62 PositionTemplate() | 62 PositionTemplate() |
63 : m_offset(0) | 63 : m_offset(0) |
64 , m_anchorType(PositionAnchorType::OffsetInAnchor) | 64 , m_anchorType(PositionAnchorType::OffsetInAnchor) |
65 { | 65 { |
66 } | 66 } |
67 | 67 |
68 static const TreeScope* commonAncestorTreeScope(const PositionTemplate<Strat
egy>&, const PositionTemplate<Strategy>& b); | 68 static const TreeScope* commonAncestorTreeScope(const PositionTemplate<Strat
egy>&, const PositionTemplate<Strategy>& b); |
69 static PositionTemplate<Strategy> editingPositionOf(PassRefPtrWillBeRawPtr<N
ode> anchorNode, int offset); | 69 static PositionTemplate<Strategy> editingPositionOf(PassRefPtrWillBeRawPtr<N
ode> anchorNode, int offset); |
(...skipping 331 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
401 | 401 |
402 } // namespace blink | 402 } // namespace blink |
403 | 403 |
404 #ifndef NDEBUG | 404 #ifndef NDEBUG |
405 // Outside the WebCore namespace for ease of invocation from gdb. | 405 // Outside the WebCore namespace for ease of invocation from gdb. |
406 void showTree(const blink::Position&); | 406 void showTree(const blink::Position&); |
407 void showTree(const blink::Position*); | 407 void showTree(const blink::Position*); |
408 #endif | 408 #endif |
409 | 409 |
410 #endif // Position_h | 410 #endif // Position_h |
OLD | NEW |