| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/automation/automation_provider_observers.h" | 5 #include "chrome/browser/automation/automation_provider_observers.h" |
| 6 | 6 |
| 7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
| 8 #include "base/json/json_writer.h" | 8 #include "base/json/json_writer.h" |
| 9 #include "base/string_util.h" | 9 #include "base/string_util.h" |
| 10 #include "chrome/app/chrome_dll_resource.h" | 10 #include "chrome/app/chrome_dll_resource.h" |
| (...skipping 664 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 675 {IDC_DUPLICATE_TAB, NotificationType::TAB_PARENTED}, | 675 {IDC_DUPLICATE_TAB, NotificationType::TAB_PARENTED}, |
| 676 {IDC_NEW_TAB, NotificationType::INITIAL_NEW_TAB_UI_LOAD}, | 676 {IDC_NEW_TAB, NotificationType::INITIAL_NEW_TAB_UI_LOAD}, |
| 677 | 677 |
| 678 // Returns as soon as the restored tab is created. To further wait until | 678 // Returns as soon as the restored tab is created. To further wait until |
| 679 // the content page is loaded, use WaitForTabToBeRestored. | 679 // the content page is loaded, use WaitForTabToBeRestored. |
| 680 {IDC_RESTORE_TAB, NotificationType::TAB_PARENTED}, | 680 {IDC_RESTORE_TAB, NotificationType::TAB_PARENTED}, |
| 681 | 681 |
| 682 // For the following commands, we need to wait for a new tab to be created, | 682 // For the following commands, we need to wait for a new tab to be created, |
| 683 // load to finish, and title to change. | 683 // load to finish, and title to change. |
| 684 {IDC_MANAGE_EXTENSIONS, NotificationType::TAB_CONTENTS_TITLE_UPDATED}, | 684 {IDC_MANAGE_EXTENSIONS, NotificationType::TAB_CONTENTS_TITLE_UPDATED}, |
| 685 {IDC_OPTIONS, NotificationType::TAB_CONTENTS_TITLE_UPDATED}, |
| 685 {IDC_SHOW_DOWNLOADS, NotificationType::TAB_CONTENTS_TITLE_UPDATED}, | 686 {IDC_SHOW_DOWNLOADS, NotificationType::TAB_CONTENTS_TITLE_UPDATED}, |
| 686 {IDC_SHOW_HISTORY, NotificationType::TAB_CONTENTS_TITLE_UPDATED}, | 687 {IDC_SHOW_HISTORY, NotificationType::TAB_CONTENTS_TITLE_UPDATED}, |
| 687 }; | 688 }; |
| 688 | 689 |
| 689 } // namespace | 690 } // namespace |
| 690 | 691 |
| 691 ExecuteBrowserCommandObserver::~ExecuteBrowserCommandObserver() { | 692 ExecuteBrowserCommandObserver::~ExecuteBrowserCommandObserver() { |
| 692 } | 693 } |
| 693 | 694 |
| 694 // static | 695 // static |
| (...skipping 340 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1035 type == NotificationType::AUTH_NEEDED) { | 1036 type == NotificationType::AUTH_NEEDED) { |
| 1036 AutomationMsg_SendJSONRequest::WriteReplyParams( | 1037 AutomationMsg_SendJSONRequest::WriteReplyParams( |
| 1037 reply_message_, std::string("{}"), false); | 1038 reply_message_, std::string("{}"), false); |
| 1038 automation_->Send(reply_message_); | 1039 automation_->Send(reply_message_); |
| 1039 delete this; | 1040 delete this; |
| 1040 } else { | 1041 } else { |
| 1041 NOTREACHED(); | 1042 NOTREACHED(); |
| 1042 } | 1043 } |
| 1043 } | 1044 } |
| 1044 | 1045 |
| OLD | NEW |