| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All | 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2012 Apple Inc. All |
| 3 * rights reserved. | 3 * rights reserved. |
| 4 * Copyright (C) 2005 Alexey Proskuryakov. | 4 * Copyright (C) 2005 Alexey Proskuryakov. |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
| 8 * are met: | 8 * are met: |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 while (m_node && !m_havePassedStartNode) { | 159 while (m_node && !m_havePassedStartNode) { |
| 160 // Don't handle node if we start iterating at [node, 0]. | 160 // Don't handle node if we start iterating at [node, 0]. |
| 161 if (!m_handledNode && !(m_node == m_endNode && !m_endOffset)) { | 161 if (!m_handledNode && !(m_node == m_endNode && !m_endOffset)) { |
| 162 LayoutObject* layoutObject = m_node->layoutObject(); | 162 LayoutObject* layoutObject = m_node->layoutObject(); |
| 163 if (layoutObject && layoutObject->isText() && | 163 if (layoutObject && layoutObject->isText() && |
| 164 m_node->getNodeType() == Node::kTextNode) { | 164 m_node->getNodeType() == Node::kTextNode) { |
| 165 // FIXME: What about kCdataSectionNode? | 165 // FIXME: What about kCdataSectionNode? |
| 166 if (layoutObject->style()->visibility() == EVisibility::kVisible && | 166 if (layoutObject->style()->visibility() == EVisibility::kVisible && |
| 167 m_offset > 0) | 167 m_offset > 0) |
| 168 m_handledNode = handleTextNode(); | 168 m_handledNode = handleTextNode(); |
| 169 } else if (layoutObject && (layoutObject->isLayoutPart() || | 169 } else if (layoutObject && |
| 170 TextIterator::supportsAltText(m_node))) { | 170 (layoutObject->isLayoutPart() || |
| 171 TextIterator::supportsAltText(m_node))) { |
| 171 if (layoutObject->style()->visibility() == EVisibility::kVisible && | 172 if (layoutObject->style()->visibility() == EVisibility::kVisible && |
| 172 m_offset > 0) | 173 m_offset > 0) |
| 173 m_handledNode = handleReplacedElement(); | 174 m_handledNode = handleReplacedElement(); |
| 174 } else { | 175 } else { |
| 175 m_handledNode = handleNonTextNode(); | 176 m_handledNode = handleNonTextNode(); |
| 176 } | 177 } |
| 177 if (m_positionNode) | 178 if (m_positionNode) |
| 178 return; | 179 return; |
| 179 } | 180 } |
| 180 | 181 |
| (...skipping 302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 483 else | 484 else |
| 484 output->pushRange(m_textContainer.characters16() + offset, copyLength); | 485 output->pushRange(m_textContainer.characters16() + offset, copyLength); |
| 485 } | 486 } |
| 486 | 487 |
| 487 template class CORE_TEMPLATE_EXPORT | 488 template class CORE_TEMPLATE_EXPORT |
| 488 SimplifiedBackwardsTextIteratorAlgorithm<EditingStrategy>; | 489 SimplifiedBackwardsTextIteratorAlgorithm<EditingStrategy>; |
| 489 template class CORE_TEMPLATE_EXPORT | 490 template class CORE_TEMPLATE_EXPORT |
| 490 SimplifiedBackwardsTextIteratorAlgorithm<EditingInFlatTreeStrategy>; | 491 SimplifiedBackwardsTextIteratorAlgorithm<EditingInFlatTreeStrategy>; |
| 491 | 492 |
| 492 } // namespace blink | 493 } // namespace blink |
| OLD | NEW |