OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv
ed. | 3 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv
ed. |
4 * | 4 * |
5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
9 * | 9 * |
10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
132 LayoutObject* startLayoutObject = startPos.anchorNode()->layoutObject(); | 132 LayoutObject* startLayoutObject = startPos.anchorNode()->layoutObject(); |
133 LayoutObject* endLayoutObject = endPos.anchorNode()->layoutObject(); | 133 LayoutObject* endLayoutObject = endPos.anchorNode()->layoutObject(); |
134 if (!startLayoutObject || !endLayoutObject) | 134 if (!startLayoutObject || !endLayoutObject) |
135 return; | 135 return; |
136 ASSERT(layoutView == startLayoutObject->view() && layoutView == endLayoutObj
ect->view()); | 136 ASSERT(layoutView == startLayoutObject->view() && layoutView == endLayoutObj
ect->view()); |
137 layoutView.setSelection(startLayoutObject, startPos.computeEditingOffset(),
endLayoutObject, endPos.computeEditingOffset()); | 137 layoutView.setSelection(startLayoutObject, startPos.computeEditingOffset(),
endLayoutObject, endPos.computeEditingOffset()); |
138 } | 138 } |
139 | 139 |
140 void PendingSelection::commit(LayoutView& layoutView) | 140 void PendingSelection::commit(LayoutView& layoutView) |
141 { | 141 { |
142 if (RuntimeEnabledFeatures::selectionForComposedTreeEnabled()) | 142 if (RuntimeEnabledFeatures::selectionForFlatTreeEnabled()) |
143 return commitAlgorithm<EditingInComposedTreeStrategy>(layoutView); | 143 return commitAlgorithm<EditingInFlatTreeStrategy>(layoutView); |
144 commitAlgorithm<EditingStrategy>(layoutView); | 144 commitAlgorithm<EditingStrategy>(layoutView); |
145 } | 145 } |
146 | 146 |
147 DEFINE_TRACE(PendingSelection) | 147 DEFINE_TRACE(PendingSelection) |
148 { | 148 { |
149 visitor->trace(m_frameSelection); | 149 visitor->trace(m_frameSelection); |
150 } | 150 } |
151 | 151 |
152 } // namespace blink | 152 } // namespace blink |
OLD | NEW |