Chromium Code Reviews| Index: content/browser/renderer_host/render_view_host.cc |
| diff --git a/content/browser/renderer_host/render_view_host.cc b/content/browser/renderer_host/render_view_host.cc |
| index 2376d887da51e22987dc3f71df514e1fe0a1a0a8..bcd60fc2715930397826a2ceff94a6c7c56cce62 100644 |
| --- a/content/browser/renderer_host/render_view_host.cc |
| +++ b/content/browser/renderer_host/render_view_host.cc |
| @@ -15,6 +15,7 @@ |
| #include "base/time.h" |
| #include "base/utf_string_conversions.h" |
| #include "base/values.h" |
| +#include "chrome/browser/google/google_util.h" |
| #include "chrome/browser/profiles/profile.h" |
| #include "content/browser/browser_message_filter.h" |
| #include "content/browser/child_process_security_policy.h" |
| @@ -63,6 +64,14 @@ namespace { |
| // Delay to wait on closing the tab for a beforeunload/unload handler to fire. |
| const int kUnloadTimeoutMS = 1000; |
| +// The URL to be opened when the "About Voice Recognition" menu item is clicked. |
| +// TODO(gshires): Replace with actual URL when proper help page is posted. |
| +const char kSpeechInputAboutUrl[] = |
| +#if defined(OS_CHROMEOS) |
|
Satish
2011/07/19 08:22:39
any reason why we need two different urls here? If
gshires
2011/07/19 22:56:31
No need to differentiate.
I made this consistent w
|
| + "https://www.google.com/support/chromeos/"; |
| +#else |
| + "https://www.google.com/support/chrome/"; |
| +#endif |
| } // namespace |
| /////////////////////////////////////////////////////////////////////////////// |
| @@ -511,6 +520,13 @@ void RenderViewHost::SelectAll() { |
| UserMetrics::RecordAction(UserMetricsAction("SelectAll")); |
| } |
| +void RenderViewHost::SpeechInputAbout() { |
| + GURL about_url(kSpeechInputAboutUrl); |
| + GURL localized_about_url = google_util::AppendGoogleLocaleParam(about_url); |
| + // Open URL with no referrer field (because user clicked on menu item). |
| + delegate_->RequestOpenURL(localized_about_url, GURL(), NEW_FOREGROUND_TAB); |
| +} |
| + |
| void RenderViewHost::JavaScriptDialogClosed(IPC::Message* reply_msg, |
| bool success, |
| const string16& user_input) { |