Chromium Code Reviews| Index: content/browser/web_contents/web_contents_impl.cc |
| diff --git a/content/browser/web_contents/web_contents_impl.cc b/content/browser/web_contents/web_contents_impl.cc |
| index 9f543642477d7a493cb31fc1dde6a3df49bc518c..f2af0269f97d22322f1ae135ad6629b2efb0e543 100644 |
| --- a/content/browser/web_contents/web_contents_impl.cc |
| +++ b/content/browser/web_contents/web_contents_impl.cc |
| @@ -48,6 +48,7 @@ |
| #include "content/public/browser/browser_context.h" |
| #include "content/public/browser/color_chooser.h" |
| #include "content/public/browser/content_browser_client.h" |
| +#include "content/public/browser/date_time_chooser.h" |
| #include "content/public/browser/devtools_agent_host.h" |
| #include "content/public/browser/download_manager.h" |
| #include "content/public/browser/download_url_parameters.h" |
| @@ -733,6 +734,8 @@ bool WebContentsImpl::OnMessageReceived(RenderViewHost* render_view_host, |
| #if defined(OS_ANDROID) |
| IPC_MESSAGE_HANDLER(ViewHostMsg_FindMatchRects_Reply, |
| OnFindMatchRectsReply) |
| + IPC_MESSAGE_HANDLER(ViewHostMsg_OpenDateTimeDialog, |
| + OnOpenDateTimeDialog) |
| #endif |
| IPC_MESSAGE_HANDLER(ViewHostMsg_CrashedPlugin, OnCrashedPlugin) |
| IPC_MESSAGE_HANDLER(ViewHostMsg_AppCacheAccessed, OnAppCacheAccessed) |
| @@ -1189,6 +1192,10 @@ void WebContentsImpl::Init(const WebContents::CreateParams& params) { |
| java_bridge_dispatcher_host_manager_.reset( |
| new JavaBridgeDispatcherHostManager(this)); |
| #endif |
| + |
| +#if defined(OS_ANDROID) |
| + date_time_chooser_.reset(DateTimeChooser::Create()); |
|
bulach
2013/01/10 15:58:35
nit: unindent
Miguel Garcia
2013/01/11 14:59:37
Done.
|
| +#endif |
| } |
| void WebContentsImpl::OnWebContentsDestroyed(WebContents* web_contents) { |
| @@ -2271,6 +2278,13 @@ void WebContentsImpl::OnFindMatchRectsReply( |
| if (delegate_) |
| delegate_->FindMatchRectsReply(this, version, rects, active_rect); |
| } |
| + |
| +void WebContentsImpl::OnOpenDateTimeDialog(int type, const std::string& value) { |
| + if (date_time_chooser_ != NULL) |
|
bulach
2013/01/10 15:58:35
can this ever be null?
Miguel Garcia
2013/01/11 14:59:37
Well not right now since this call is compiled out
|
| + date_time_chooser_->ShowDialog( |
| + GetContentNativeView(), GetRenderViewHost(), type, value); |
| +} |
| + |
| #endif |
| void WebContentsImpl::OnCrashedPlugin(const FilePath& plugin_path) { |