| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef COMPONENTS_TEST_RUNNER_SPELL_CHECK_CLIENT_H_ | 5 #ifndef COMPONENTS_TEST_RUNNER_SPELL_CHECK_CLIENT_H_ |
| 6 #define COMPONENTS_TEST_RUNNER_SPELL_CHECK_CLIENT_H_ | 6 #define COMPONENTS_TEST_RUNNER_SPELL_CHECK_CLIENT_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| (...skipping 28 matching lines...) Expand all Loading... |
| 39 blink::WebVector<blink::WebString>* optional_suggestions) override; | 39 blink::WebVector<blink::WebString>* optional_suggestions) override; |
| 40 void checkTextOfParagraph( | 40 void checkTextOfParagraph( |
| 41 const blink::WebString& text, | 41 const blink::WebString& text, |
| 42 blink::WebTextCheckingTypeMask mask, | 42 blink::WebTextCheckingTypeMask mask, |
| 43 blink::WebVector<blink::WebTextCheckingResult>* web_results) override; | 43 blink::WebVector<blink::WebTextCheckingResult>* web_results) override; |
| 44 void requestCheckingOfText( | 44 void requestCheckingOfText( |
| 45 const blink::WebString& text, | 45 const blink::WebString& text, |
| 46 const blink::WebVector<uint32_t>& markers, | 46 const blink::WebVector<uint32_t>& markers, |
| 47 const blink::WebVector<unsigned>& marker_offsets, | 47 const blink::WebVector<unsigned>& marker_offsets, |
| 48 blink::WebTextCheckingCompletion* completion) override; | 48 blink::WebTextCheckingCompletion* completion) override; |
| 49 void cancelAllPendingRequests() override; |
| 49 | 50 |
| 50 private: | 51 private: |
| 51 void FinishLastTextCheck(); | 52 void FinishLastTextCheck(); |
| 52 | 53 |
| 53 // The mock spellchecker used in spellCheck(). | 54 // The mock spellchecker used in spellCheck(). |
| 54 MockSpellCheck spell_check_; | 55 MockSpellCheck spell_check_; |
| 55 | 56 |
| 56 blink::WebString last_requested_text_check_string_; | 57 blink::WebString last_requested_text_check_string_; |
| 57 blink::WebTextCheckingCompletion* last_requested_text_checking_completion_; | 58 blink::WebTextCheckingCompletion* last_requested_text_checking_completion_; |
| 58 | 59 |
| 59 TestRunner* test_runner_; | 60 TestRunner* test_runner_; |
| 60 WebTestDelegate* delegate_; | 61 WebTestDelegate* delegate_; |
| 61 | 62 |
| 62 base::WeakPtrFactory<SpellCheckClient> weak_factory_; | 63 base::WeakPtrFactory<SpellCheckClient> weak_factory_; |
| 63 | 64 |
| 64 DISALLOW_COPY_AND_ASSIGN(SpellCheckClient); | 65 DISALLOW_COPY_AND_ASSIGN(SpellCheckClient); |
| 65 }; | 66 }; |
| 66 | 67 |
| 67 } // namespace test_runner | 68 } // namespace test_runner |
| 68 | 69 |
| 69 #endif // COMPONENTS_TEST_RUNNER_SPELL_CHECK_CLIENT_H_ | 70 #endif // COMPONENTS_TEST_RUNNER_SPELL_CHECK_CLIENT_H_ |
| OLD | NEW |