| 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/browser/renderer_host/render_view_host.h" |     5 #include "chrome/browser/renderer_host/render_view_host.h" | 
|     6  |     6  | 
|     7 #include <string> |     7 #include <string> | 
|     8 #include <utility> |     8 #include <utility> | 
|     9 #include <vector> |     9 #include <vector> | 
|    10  |    10  | 
| (...skipping 1985 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  1996 } |  1996 } | 
|  1997  |  1997  | 
|  1998 void RenderViewHost::PerformCustomContextMenuAction(unsigned action) { |  1998 void RenderViewHost::PerformCustomContextMenuAction(unsigned action) { | 
|  1999   Send(new ViewMsg_CustomContextMenuAction(routing_id(), action)); |  1999   Send(new ViewMsg_CustomContextMenuAction(routing_id(), action)); | 
|  2000 } |  2000 } | 
|  2001  |  2001  | 
|  2002 void RenderViewHost::TranslatePage(int page_id, |  2002 void RenderViewHost::TranslatePage(int page_id, | 
|  2003                                    const std::string& translate_script, |  2003                                    const std::string& translate_script, | 
|  2004                                    const std::string& source_lang, |  2004                                    const std::string& source_lang, | 
|  2005                                    const std::string& target_lang) { |  2005                                    const std::string& target_lang) { | 
 |  2006   // Ideally we'd have a better way to uniquely identify form control elements, | 
 |  2007   // but we don't have that yet.  So before start translation, we clear the | 
 |  2008   // current form and re-parse it in AutoFillManter first to get the new | 
 |  2009   // labels. | 
 |  2010   RenderViewHostDelegate::AutoFill* autofill_delegate = | 
 |  2011       delegate_->GetAutoFillDelegate(); | 
 |  2012   if (autofill_delegate) | 
 |  2013     autofill_delegate->Reset(); | 
 |  2014  | 
|  2006   Send(new ViewMsg_TranslatePage(routing_id(), page_id, translate_script, |  2015   Send(new ViewMsg_TranslatePage(routing_id(), page_id, translate_script, | 
|  2007                                  source_lang, target_lang)); |  2016                                  source_lang, target_lang)); | 
|  2008 } |  2017 } | 
|  2009  |  2018  | 
|  2010 void RenderViewHost::RevertTranslation(int page_id) { |  2019 void RenderViewHost::RevertTranslation(int page_id) { | 
|  2011   Send(new ViewMsg_RevertTranslation(routing_id(), page_id)); |  2020   Send(new ViewMsg_RevertTranslation(routing_id(), page_id)); | 
|  2012 } |  2021 } | 
|  2013  |  2022  | 
|  2014 void RenderViewHost::SendContentSettings(const GURL& url, |  2023 void RenderViewHost::SendContentSettings(const GURL& url, | 
|  2015                                          const ContentSettings& settings) { |  2024                                          const ContentSettings& settings) { | 
| (...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  2244   TabContents* print_preview_tab = GetOrCreatePrintPreviewTab(); |  2253   TabContents* print_preview_tab = GetOrCreatePrintPreviewTab(); | 
|  2245   DCHECK(print_preview_tab); |  2254   DCHECK(print_preview_tab); | 
|  2246  |  2255  | 
|  2247   // TODO(kmadhusu): Function definition needs to be changed. |  2256   // TODO(kmadhusu): Function definition needs to be changed. | 
|  2248   // fd_in_browser should be the file descriptor of the metafile. |  2257   // fd_in_browser should be the file descriptor of the metafile. | 
|  2249  |  2258  | 
|  2250   // Send the printingDone msg for now. |  2259   // Send the printingDone msg for now. | 
|  2251   Send(new ViewMsg_PrintingDone(routing_id(), -1, true)); |  2260   Send(new ViewMsg_PrintingDone(routing_id(), -1, true)); | 
|  2252 } |  2261 } | 
|  2253 #endif |  2262 #endif | 
| OLD | NEW |