OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007 Apple Inc. All rights reserved. |
3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
130 void TextCheckingParagraph::expandRangeToNextEnd() | 130 void TextCheckingParagraph::expandRangeToNextEnd() |
131 { | 131 { |
132 ASSERT(m_checkingRange); | 132 ASSERT(m_checkingRange); |
133 setEnd(paragraphRange().get(), endOfParagraph(startOfNextParagraph(paragraph
Range()->startPosition()))); | 133 setEnd(paragraphRange().get(), endOfParagraph(startOfNextParagraph(paragraph
Range()->startPosition()))); |
134 invalidateParagraphRangeValues(); | 134 invalidateParagraphRangeValues(); |
135 } | 135 } |
136 | 136 |
137 void TextCheckingParagraph::invalidateParagraphRangeValues() | 137 void TextCheckingParagraph::invalidateParagraphRangeValues() |
138 { | 138 { |
139 m_checkingStart = m_checkingEnd = -1; | 139 m_checkingStart = m_checkingEnd = -1; |
140 m_offsetAsRange = 0; | 140 m_offsetAsRange = nullptr; |
141 m_text = String(); | 141 m_text = String(); |
142 } | 142 } |
143 | 143 |
144 int TextCheckingParagraph::rangeLength() const | 144 int TextCheckingParagraph::rangeLength() const |
145 { | 145 { |
146 ASSERT(m_checkingRange); | 146 ASSERT(m_checkingRange); |
147 return TextIterator::rangeLength(paragraphRange().get()); | 147 return TextIterator::rangeLength(paragraphRange().get()); |
148 } | 148 } |
149 | 149 |
150 PassRefPtr<Range> TextCheckingParagraph::paragraphRange() const | 150 PassRefPtr<Range> TextCheckingParagraph::paragraphRange() const |
(...skipping 418 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
569 return false; | 569 return false; |
570 | 570 |
571 const Settings* settings = frame->settings(); | 571 const Settings* settings = frame->settings(); |
572 if (!settings) | 572 if (!settings) |
573 return false; | 573 return false; |
574 | 574 |
575 return settings->unifiedTextCheckerEnabled(); | 575 return settings->unifiedTextCheckerEnabled(); |
576 } | 576 } |
577 | 577 |
578 } | 578 } |
OLD | NEW |