| 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 1622 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1633 | 1633 |
| 1634 void RenderViewHost::OnRemoveAutocompleteEntry(const string16& field_name, | 1634 void RenderViewHost::OnRemoveAutocompleteEntry(const string16& field_name, |
| 1635 const string16& value) { | 1635 const string16& value) { |
| 1636 RenderViewHostDelegate::Autocomplete* autocomplete_delegate = | 1636 RenderViewHostDelegate::Autocomplete* autocomplete_delegate = |
| 1637 delegate_->GetAutocompleteDelegate(); | 1637 delegate_->GetAutocompleteDelegate(); |
| 1638 if (autocomplete_delegate) | 1638 if (autocomplete_delegate) |
| 1639 autocomplete_delegate->RemoveAutocompleteEntry(field_name, value); | 1639 autocomplete_delegate->RemoveAutocompleteEntry(field_name, value); |
| 1640 } | 1640 } |
| 1641 | 1641 |
| 1642 void RenderViewHost::OnShowAutoFillDialog() { | 1642 void RenderViewHost::OnShowAutoFillDialog() { |
| 1643 if (CommandLine::ForCurrentProcess()->HasSwitch( | 1643 if (!CommandLine::ForCurrentProcess()->HasSwitch( |
| 1644 switches::kEnableTabbedOptions)) { | 1644 switches::kDisableTabbedOptions)) { |
| 1645 Browser* browser = BrowserList::GetLastActive(); | 1645 Browser* browser = BrowserList::GetLastActive(); |
| 1646 if (!browser) | 1646 if (!browser) |
| 1647 return; | 1647 return; |
| 1648 browser->ShowOptionsTab(chrome::kAutoFillSubPage); | 1648 browser->ShowOptionsTab(chrome::kAutoFillSubPage); |
| 1649 } else { | 1649 } else { |
| 1650 RenderViewHostDelegate::AutoFill* autofill_delegate = | 1650 RenderViewHostDelegate::AutoFill* autofill_delegate = |
| 1651 delegate_->GetAutoFillDelegate(); | 1651 delegate_->GetAutoFillDelegate(); |
| 1652 if (!autofill_delegate) | 1652 if (!autofill_delegate) |
| 1653 return; | 1653 return; |
| 1654 | 1654 |
| (...skipping 525 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2180 if (printer_query.get()) { | 2180 if (printer_query.get()) { |
| 2181 BrowserThread::PostTask( | 2181 BrowserThread::PostTask( |
| 2182 BrowserThread::IO, FROM_HERE, | 2182 BrowserThread::IO, FROM_HERE, |
| 2183 NewRunnableMethod(printer_query.get(), | 2183 NewRunnableMethod(printer_query.get(), |
| 2184 &printing::PrinterQuery::StopWorker)); | 2184 &printing::PrinterQuery::StopWorker)); |
| 2185 } | 2185 } |
| 2186 | 2186 |
| 2187 // Send the printingDone msg for now. | 2187 // Send the printingDone msg for now. |
| 2188 Send(new ViewMsg_PrintingDone(routing_id(), params.document_cookie, true)); | 2188 Send(new ViewMsg_PrintingDone(routing_id(), params.document_cookie, true)); |
| 2189 } | 2189 } |
| OLD | NEW |