Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(601)

Side by Side Diff: Source/core/editing/SpellChecker.cpp

Issue 21024004: Add/remove spell checking markers in text inputs depending on focus. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Clean up in the test & the new expected file. Created 7 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/editing/Editor.cpp ('k') | Source/core/html/HTMLInputElement.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google 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 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 if (m_timerToProcessQueuedRequest.isActive() || m_processingRequest) { 184 if (m_timerToProcessQueuedRequest.isActive() || m_processingRequest) {
185 enqueueRequest(request); 185 enqueueRequest(request);
186 return; 186 return;
187 } 187 }
188 188
189 invokeRequest(request); 189 invokeRequest(request);
190 } 190 }
191 191
192 void SpellChecker::cancelCheck() 192 void SpellChecker::cancelCheck()
193 { 193 {
194 if (!m_requestQueue.isEmpty())
195 m_requestQueue.clear();
196 if (m_processingRequest) 194 if (m_processingRequest)
197 m_processingRequest->didCancel(); 195 m_processingRequest->didCancel();
198 } 196 }
199 197
200 void SpellChecker::invokeRequest(PassRefPtr<SpellCheckRequest> request) 198 void SpellChecker::invokeRequest(PassRefPtr<SpellCheckRequest> request)
201 { 199 {
202 ASSERT(!m_processingRequest); 200 ASSERT(!m_processingRequest);
203 if (!client()) 201 if (!client())
204 return; 202 return;
205 m_processingRequest = request; 203 m_processingRequest = request;
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
255 didCheck(sequence, results); 253 didCheck(sequence, results);
256 } 254 }
257 255
258 void SpellChecker::didCheckCancel(int sequence) 256 void SpellChecker::didCheckCancel(int sequence)
259 { 257 {
260 Vector<TextCheckingResult> results; 258 Vector<TextCheckingResult> results;
261 didCheck(sequence, results); 259 didCheck(sequence, results);
262 } 260 }
263 261
264 } // namespace WebCore 262 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/editing/Editor.cpp ('k') | Source/core/html/HTMLInputElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698