OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 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 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 | 150 |
151 if (renderer->style()->visibility() != VISIBLE) | 151 if (renderer->style()->visibility() != VISIBLE) |
152 return false; | 152 return false; |
153 | 153 |
154 if (renderer->isBR()) | 154 if (renderer->isBR()) |
155 return !m_offsetInAnchor && !Position::nodeIsUserSelectNone(m_anchorNode
->parentNode()); | 155 return !m_offsetInAnchor && !Position::nodeIsUserSelectNone(m_anchorNode
->parentNode()); |
156 | 156 |
157 if (renderer->isText()) | 157 if (renderer->isText()) |
158 return !Position::nodeIsUserSelectNone(m_anchorNode) && Position(*this).
inRenderedText(); | 158 return !Position::nodeIsUserSelectNone(m_anchorNode) && Position(*this).
inRenderedText(); |
159 | 159 |
160 if (isTableElement(m_anchorNode) || editingIgnoresContent(m_anchorNode)) | 160 if (isRenderedTable(m_anchorNode) || editingIgnoresContent(m_anchorNode)) |
161 return (atStartOfNode() || atEndOfNode()) && !Position::nodeIsUserSelect
None(m_anchorNode->parentNode()); | 161 return (atStartOfNode() || atEndOfNode()) && !Position::nodeIsUserSelect
None(m_anchorNode->parentNode()); |
162 | 162 |
163 if (!isHTMLHtmlElement(m_anchorNode) && renderer->isRenderBlockFlow()) { | 163 if (!isHTMLHtmlElement(m_anchorNode) && renderer->isRenderBlockFlow()) { |
164 if (toRenderBlock(renderer)->logicalHeight() || m_anchorNode->hasTagName
(bodyTag)) { | 164 if (toRenderBlock(renderer)->logicalHeight() || m_anchorNode->hasTagName
(bodyTag)) { |
165 if (!Position::hasRenderedNonAnonymousDescendantsWithHeight(renderer
)) | 165 if (!Position::hasRenderedNonAnonymousDescendantsWithHeight(renderer
)) |
166 return atStartOfNode() && !Position::nodeIsUserSelectNone(m_anch
orNode); | 166 return atStartOfNode() && !Position::nodeIsUserSelectNone(m_anch
orNode); |
167 return m_anchorNode->rendererIsEditable() && !Position::nodeIsUserSe
lectNone(m_anchorNode) && Position(*this).atEditingBoundary(); | 167 return m_anchorNode->rendererIsEditable() && !Position::nodeIsUserSe
lectNone(m_anchorNode) && Position(*this).atEditingBoundary(); |
168 } | 168 } |
169 } | 169 } |
170 | 170 |
171 return false; | 171 return false; |
172 } | 172 } |
173 | 173 |
174 } // namespace WebCore | 174 } // namespace WebCore |
OLD | NEW |