OLD | NEW |
1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "core/editing/spellcheck/HotModeSpellCheckRequester.h" | 5 #include "core/editing/spellcheck/HotModeSpellCheckRequester.h" |
6 | 6 |
7 #include "core/editing/EditingUtilities.h" | 7 #include "core/editing/EditingUtilities.h" |
8 #include "core/editing/Editor.h" | 8 #include "core/editing/Editor.h" |
9 #include "core/editing/VisiblePosition.h" | 9 #include "core/editing/VisiblePosition.h" |
10 #include "core/editing/commands/CompositeEditCommand.h" | 10 #include "core/editing/commands/CompositeEditCommand.h" |
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 if (!rootEditable || !rootEditable->isConnected()) | 93 if (!rootEditable || !rootEditable->isConnected()) |
94 return; | 94 return; |
95 | 95 |
96 if (m_processedRootEditables.contains(rootEditable)) | 96 if (m_processedRootEditables.contains(rootEditable)) |
97 return; | 97 return; |
98 m_processedRootEditables.push_back(rootEditable); | 98 m_processedRootEditables.push_back(rootEditable); |
99 | 99 |
100 if (!shouldCheckRootEditableInHotMode(*rootEditable, position)) | 100 if (!shouldCheckRootEditableInHotMode(*rootEditable, position)) |
101 return; | 101 return; |
102 | 102 |
103 SpellCheckRequest* request = SpellCheckRequest::create( | 103 const EphemeralRange& checkingRange = |
104 calculateHotModeCheckingRange(*rootEditable, position)); | 104 calculateHotModeCheckingRange(*rootEditable, position); |
105 m_requester->requestCheckingFor(request); | 105 m_requester->requestCheckingFor(checkingRange); |
106 } | 106 } |
107 | 107 |
108 } // namespace blink | 108 } // namespace blink |
OLD | NEW |