OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 "chrome/renderer/search_extension.h" | 5 #include "chrome/renderer/search_extension.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
11 #include "chrome/common/render_messages_params.h" | |
12 #include "chrome/renderer/searchbox.h" | 11 #include "chrome/renderer/searchbox.h" |
13 #include "content/renderer/render_view.h" | 12 #include "content/renderer/render_view.h" |
14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" | 13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" |
15 #include "v8/include/v8.h" | 14 #include "v8/include/v8.h" |
16 | 15 |
17 using WebKit::WebFrame; | 16 using WebKit::WebFrame; |
18 using WebKit::WebView; | 17 using WebKit::WebView; |
19 | 18 |
20 namespace extensions_v8 { | 19 namespace extensions_v8 { |
21 | 20 |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 suggestions.push_back(std::string(*v8::String::Utf8Value(args[0]))); | 84 suggestions.push_back(std::string(*v8::String::Utf8Value(args[0]))); |
86 render_view->searchbox()->SetSuggestions(suggestions, INSTANT_COMPLETE_NOW); | 85 render_view->searchbox()->SetSuggestions(suggestions, INSTANT_COMPLETE_NOW); |
87 return v8::Undefined(); | 86 return v8::Undefined(); |
88 } | 87 } |
89 | 88 |
90 v8::Extension* SearchExtension::Get() { | 89 v8::Extension* SearchExtension::Get() { |
91 return new SearchExtensionWrapper(); | 90 return new SearchExtensionWrapper(); |
92 } | 91 } |
93 | 92 |
94 } // namespace extensions_v8 | 93 } // namespace extensions_v8 |
OLD | NEW |