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

Side by Side Diff: components/spellcheck/common/spellcheck_messages.h

Issue 2818043002: Make SpellCheckPanel compiled and used only on Mac (Closed)
Patch Set: Thu Apr 13 18:29:22 PDT 2017 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 | « components/spellcheck/BUILD.gn ('k') | components/spellcheck/renderer/BUILD.gn » ('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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // IPC messages for spellcheck. 5 // IPC messages for spellcheck.
6 // Multiply-included message file, hence no include guard. 6 // Multiply-included message file, hence no include guard.
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "components/spellcheck/common/spellcheck_bdict_language.h" 10 #include "components/spellcheck/common/spellcheck_bdict_language.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 // If the service is not available, the 4th parameter should be false and the 56 // If the service is not available, the 4th parameter should be false and the
57 // 5th parameter should contain the requested sentence. 57 // 5th parameter should contain the requested sentence.
58 IPC_MESSAGE_ROUTED4(SpellCheckMsg_RespondSpellingService, 58 IPC_MESSAGE_ROUTED4(SpellCheckMsg_RespondSpellingService,
59 int /* request identifier given by WebKit */, 59 int /* request identifier given by WebKit */,
60 bool /* succeeded calling service */, 60 bool /* succeeded calling service */,
61 base::string16 /* sentence */, 61 base::string16 /* sentence */,
62 std::vector<SpellCheckResult>) 62 std::vector<SpellCheckResult>)
63 #endif 63 #endif
64 64
65 #if BUILDFLAG(USE_BROWSER_SPELLCHECKER) 65 #if BUILDFLAG(USE_BROWSER_SPELLCHECKER)
66 // This message tells the renderer to advance to the next misspelling. It is
67 // sent when the user clicks the "Find Next" button on the spelling panel.
68 IPC_MESSAGE_ROUTED0(SpellCheckMsg_AdvanceToNextMisspelling)
69
70 // Sends when NSSpellChecker finishes checking text received by a preceding 66 // Sends when NSSpellChecker finishes checking text received by a preceding
71 // SpellCheckHostMsg_RequestTextCheck message. 67 // SpellCheckHostMsg_RequestTextCheck message.
72 IPC_MESSAGE_ROUTED3(SpellCheckMsg_RespondTextCheck, 68 IPC_MESSAGE_ROUTED3(SpellCheckMsg_RespondTextCheck,
73 int /* request identifier given by WebKit */, 69 int /* request identifier given by WebKit */,
74 base::string16 /* sentence */, 70 base::string16 /* sentence */,
75 std::vector<SpellCheckResult>) 71 std::vector<SpellCheckResult>)
72 #endif
73
74 #if BUILDFLAG(HAS_SPELLCHECK_PANEL)
75 // This message tells the renderer to advance to the next misspelling. It is
76 // sent when the user clicks the "Find Next" button on the spelling panel.
77 IPC_MESSAGE_ROUTED0(SpellCheckMsg_AdvanceToNextMisspelling)
76 78
77 IPC_MESSAGE_ROUTED1(SpellCheckMsg_ToggleSpellPanel, bool) 79 IPC_MESSAGE_ROUTED1(SpellCheckMsg_ToggleSpellPanel, bool)
78 #endif 80 #endif
79 81
80 // Messages sent from the renderer to the browser. 82 // Messages sent from the renderer to the browser.
81 83
82 // The renderer has tried to spell check a word, but couldn't because no 84 // The renderer has tried to spell check a word, but couldn't because no
83 // dictionary was available to load. Request that the browser find an 85 // dictionary was available to load. Request that the browser find an
84 // appropriate dictionary and return it. 86 // appropriate dictionary and return it.
85 IPC_MESSAGE_CONTROL0(SpellCheckHostMsg_RequestDictionary) 87 IPC_MESSAGE_CONTROL0(SpellCheckHostMsg_RequestDictionary)
86 88
87 // Tracks spell checking occurrence to collect histogram. 89 // Tracks spell checking occurrence to collect histogram.
88 IPC_MESSAGE_ROUTED2(SpellCheckHostMsg_NotifyChecked, 90 IPC_MESSAGE_ROUTED2(SpellCheckHostMsg_NotifyChecked,
89 base::string16 /* word */, 91 base::string16 /* word */,
90 bool /* true if checked word is misspelled */) 92 bool /* true if checked word is misspelled */)
91 93
92 #if !BUILDFLAG(USE_BROWSER_SPELLCHECKER) 94 #if !BUILDFLAG(USE_BROWSER_SPELLCHECKER)
93 // Asks the Spelling service to check text. When the service finishes checking 95 // Asks the Spelling service to check text. When the service finishes checking
94 // the input text, it sends a SpellingCheckMsg_RespondSpellingService with 96 // the input text, it sends a SpellingCheckMsg_RespondSpellingService with
95 // text-check results. 97 // text-check results.
96 IPC_MESSAGE_CONTROL3(SpellCheckHostMsg_CallSpellingService, 98 IPC_MESSAGE_CONTROL3(SpellCheckHostMsg_CallSpellingService,
97 int /* route_id for response */, 99 int /* route_id for response */,
98 int /* request identifier given by WebKit */, 100 int /* request identifier given by WebKit */,
99 base::string16 /* sentence */) 101 base::string16 /* sentence */)
100 #endif 102 #endif
101 103
102 #if BUILDFLAG(USE_BROWSER_SPELLCHECKER) 104 #if BUILDFLAG(USE_BROWSER_SPELLCHECKER)
103 // Tells the browser to display or not display the SpellingPanel
104 IPC_MESSAGE_ROUTED1(SpellCheckHostMsg_ShowSpellingPanel,
105 bool /* if true, then show it, otherwise hide it*/)
106
107 // Tells the browser to update the spelling panel with the given word.
108 IPC_MESSAGE_ROUTED1(SpellCheckHostMsg_UpdateSpellingPanelWithMisspelledWord,
109 base::string16 /* the word to update the panel with */)
110
111 // TODO(groby): This needs to originate from SpellcheckProvider. 105 // TODO(groby): This needs to originate from SpellcheckProvider.
112 IPC_SYNC_MESSAGE_CONTROL2_1(SpellCheckHostMsg_CheckSpelling, 106 IPC_SYNC_MESSAGE_CONTROL2_1(SpellCheckHostMsg_CheckSpelling,
113 base::string16 /* word */, 107 base::string16 /* word */,
114 int /* route_id */, 108 int /* route_id */,
115 bool /* correct */) 109 bool /* correct */)
116 110
117 IPC_SYNC_MESSAGE_CONTROL1_1(SpellCheckHostMsg_FillSuggestionList, 111 IPC_SYNC_MESSAGE_CONTROL1_1(SpellCheckHostMsg_FillSuggestionList,
118 base::string16 /* word */, 112 base::string16 /* word */,
119 std::vector<base::string16> /* suggestions */) 113 std::vector<base::string16> /* suggestions */)
120 114
121 IPC_MESSAGE_CONTROL3(SpellCheckHostMsg_RequestTextCheck, 115 IPC_MESSAGE_CONTROL3(SpellCheckHostMsg_RequestTextCheck,
122 int /* route_id for response */, 116 int /* route_id for response */,
123 int /* request identifier given by WebKit */, 117 int /* request identifier given by WebKit */,
124 base::string16 /* sentence */) 118 base::string16 /* sentence */)
125 119
126 IPC_MESSAGE_ROUTED2(SpellCheckHostMsg_ToggleSpellCheck, 120 IPC_MESSAGE_ROUTED2(SpellCheckHostMsg_ToggleSpellCheck,
127 bool /* enabled */, 121 bool /* enabled */,
128 bool /* checked */) 122 bool /* checked */)
129 #endif // USE_BROWSER_SPELLCHECKER 123 #endif // USE_BROWSER_SPELLCHECKER
124
125 #if BUILDFLAG(HAS_SPELLCHECK_PANEL)
126 // Tells the browser to display or not display the SpellingPanel
127 IPC_MESSAGE_ROUTED1(SpellCheckHostMsg_ShowSpellingPanel,
128 bool /* if true, then show it, otherwise hide it*/)
129
130 // Tells the browser to update the spelling panel with the given word.
131 IPC_MESSAGE_ROUTED1(SpellCheckHostMsg_UpdateSpellingPanelWithMisspelledWord,
132 base::string16 /* the word to update the panel with */)
133 #endif
please use gerrit instead 2017/04/14 14:19:58 Since you're moving these around, would you mind g
Xiaocheng 2017/04/14 17:27:35 The messages are grouped as "from renderer to brow
OLDNEW
« no previous file with comments | « components/spellcheck/BUILD.gn ('k') | components/spellcheck/renderer/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698