OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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.h" | 5 #include "chrome/browser/automation/automation_provider.h" |
6 | 6 |
7 #include <set> | 7 #include <set> |
8 | 8 |
9 #include "base/callback.h" | 9 #include "base/callback.h" |
10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
(...skipping 802 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
813 (extension->location() == Extension::INTERNAL || | 813 (extension->location() == Extension::INTERNAL || |
814 extension->location() == Extension::LOAD)) { | 814 extension->location() == Extension::LOAD)) { |
815 result->push_back(extension->path()); | 815 result->push_back(extension->path()); |
816 } | 816 } |
817 } | 817 } |
818 } | 818 } |
819 } | 819 } |
820 | 820 |
821 void AutomationProvider::WaitForExtensionTestResult( | 821 void AutomationProvider::WaitForExtensionTestResult( |
822 IPC::Message* reply_message) { | 822 IPC::Message* reply_message) { |
823 DCHECK(reply_message_ == NULL); | 823 DCHECK(!reply_message_); |
824 reply_message_ = reply_message; | 824 reply_message_ = reply_message; |
825 // Call MaybeSendResult, because the result might have come in before | 825 // Call MaybeSendResult, because the result might have come in before |
826 // we were waiting on it. | 826 // we were waiting on it. |
827 extension_test_result_observer_->MaybeSendResult(); | 827 extension_test_result_observer_->MaybeSendResult(); |
828 } | 828 } |
829 | 829 |
830 void AutomationProvider::InstallExtensionAndGetHandle( | 830 void AutomationProvider::InstallExtensionAndGetHandle( |
831 const FilePath& crx_path, bool with_ui, IPC::Message* reply_message) { | 831 const FilePath& crx_path, bool with_ui, IPC::Message* reply_message) { |
832 ExtensionService* service = profile_->GetExtensionService(); | 832 ExtensionService* service = profile_->GetExtensionService(); |
833 ExtensionProcessManager* manager = profile_->GetExtensionProcessManager(); | 833 ExtensionProcessManager* manager = profile_->GetExtensionProcessManager(); |
(...skipping 158 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
992 } | 992 } |
993 } | 993 } |
994 } | 994 } |
995 | 995 |
996 void AutomationProvider::SaveAsAsync(int tab_handle) { | 996 void AutomationProvider::SaveAsAsync(int tab_handle) { |
997 NavigationController* tab = NULL; | 997 NavigationController* tab = NULL; |
998 TabContents* tab_contents = GetTabContentsForHandle(tab_handle, &tab); | 998 TabContents* tab_contents = GetTabContentsForHandle(tab_handle, &tab); |
999 if (tab_contents) | 999 if (tab_contents) |
1000 tab_contents->OnSavePage(); | 1000 tab_contents->OnSavePage(); |
1001 } | 1001 } |
OLD | NEW |