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

Side by Side Diff: third_party/WebKit/Source/core/editing/spellcheck/SpellCheckTestBase.h

Issue 2795113002: Move ownership of TextCheckerClientImpl to WebLocalFrameImpl (Closed)
Patch Set: Rebased Created 3 years, 8 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 | « no previous file | third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #ifndef SpellCheckTestBase_h 5 #ifndef SpellCheckTestBase_h
6 #define SpellCheckTestBase_h 6 #define SpellCheckTestBase_h
7 7
8 #include "core/editing/EditingTestBase.h" 8 #include "core/editing/EditingTestBase.h"
9 #include "core/loader/EmptyClients.h" 9 #include "core/loader/EmptyClients.h"
10 #include "core/testing/DummyPageHolder.h" 10 #include "core/testing/DummyPageHolder.h"
11 11
12 namespace blink { 12 namespace blink {
13 13
14 class SpellCheckTestBase : public EditingTestBase { 14 class SpellCheckTestBase : public EditingTestBase {
15 protected: 15 protected:
16 void SetUp() override; 16 void SetUp() override;
17 17
18 private: 18 private:
19 class DummySpellCheckerClient : public EmptySpellCheckerClient { 19 class DummySpellCheckerClient : public EmptySpellCheckerClient {
20 public: 20 public:
21 virtual ~DummySpellCheckerClient() {} 21 virtual ~DummySpellCheckerClient() {}
22 22
23 bool isSpellCheckingEnabled() override { return true; } 23 bool isSpellCheckingEnabled() override { return true; }
24
25 TextCheckerClient& textChecker() override {
26 return m_emptyTextCheckerClient;
27 }
28
29 private:
30 EmptyTextCheckerClient m_emptyTextCheckerClient;
31 }; 24 };
32 25
33 std::unique_ptr<DummySpellCheckerClient> m_spellCheckerClient; 26 std::unique_ptr<DummySpellCheckerClient> m_spellCheckerClient;
34 }; 27 };
35 28
36 } // namespace blink 29 } // namespace blink
37 30
38 #endif // SpellCheckTestBase_h 31 #endif // SpellCheckTestBase_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/editing/spellcheck/SpellChecker.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698