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 #include "content/shell/renderer/test_runner/event_sender.h" | 5 #include "content/shell/renderer/test_runner/event_sender.h" |
6 | 6 |
7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/strings/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
10 #include "content/public/common/page_zoom.h" | 10 #include "content/public/common/page_zoom.h" |
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
170 if (!context_menu) | 170 if (!context_menu) |
171 return std::vector<std::string>(); | 171 return std::vector<std::string>(); |
172 | 172 |
173 std::vector<std::string> strings; | 173 std::vector<std::string> strings; |
174 | 174 |
175 if (context_menu->isEditable) { | 175 if (context_menu->isEditable) { |
176 for (const char** item = kEditableMenuStrings; *item; ++item) { | 176 for (const char** item = kEditableMenuStrings; *item; ++item) { |
177 strings.push_back(*item); | 177 strings.push_back(*item); |
178 } | 178 } |
179 WebVector<WebString> suggestions; | 179 WebVector<WebString> suggestions; |
180 WebTestRunner::MockSpellCheck::fillSuggestionList( | 180 MockSpellCheck::fillSuggestionList( |
181 context_menu->misspelledWord, &suggestions); | 181 context_menu->misspelledWord, &suggestions); |
182 for (size_t i = 0; i < suggestions.size(); ++i) { | 182 for (size_t i = 0; i < suggestions.size(); ++i) { |
183 strings.push_back(suggestions[i].utf8()); | 183 strings.push_back(suggestions[i].utf8()); |
184 } | 184 } |
185 } else { | 185 } else { |
186 for (const char** item = kNonEditableMenuStrings; *item; ++item) { | 186 for (const char** item = kNonEditableMenuStrings; *item; ++item) { |
187 strings.push_back(*item); | 187 strings.push_back(*item); |
188 } | 188 } |
189 } | 189 } |
190 | 190 |
(...skipping 1980 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2171 } | 2171 } |
2172 default: | 2172 default: |
2173 NOTREACHED(); | 2173 NOTREACHED(); |
2174 } | 2174 } |
2175 } | 2175 } |
2176 | 2176 |
2177 replaying_saved_events_ = false; | 2177 replaying_saved_events_ = false; |
2178 } | 2178 } |
2179 | 2179 |
2180 } // namespace content | 2180 } // namespace content |
OLD | NEW |