OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/testing_automation_provider.h" | 5 #include "chrome/browser/automation/testing_automation_provider.h" |
6 | 6 |
7 #include <map> | 7 #include <map> |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 1756 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1767 handler_map["SimulateAsanMemoryBug"] = | 1767 handler_map["SimulateAsanMemoryBug"] = |
1768 &TestingAutomationProvider::SimulateAsanMemoryBug; | 1768 &TestingAutomationProvider::SimulateAsanMemoryBug; |
1769 | 1769 |
1770 #if defined(OS_CHROMEOS) | 1770 #if defined(OS_CHROMEOS) |
1771 handler_map["GetLoginInfo"] = &TestingAutomationProvider::GetLoginInfo; | 1771 handler_map["GetLoginInfo"] = &TestingAutomationProvider::GetLoginInfo; |
1772 handler_map["ShowCreateAccountUI"] = | 1772 handler_map["ShowCreateAccountUI"] = |
1773 &TestingAutomationProvider::ShowCreateAccountUI; | 1773 &TestingAutomationProvider::ShowCreateAccountUI; |
1774 handler_map["ExecuteJavascriptInOOBEWebUI"] = | 1774 handler_map["ExecuteJavascriptInOOBEWebUI"] = |
1775 &TestingAutomationProvider::ExecuteJavascriptInOOBEWebUI; | 1775 &TestingAutomationProvider::ExecuteJavascriptInOOBEWebUI; |
1776 handler_map["LoginAsGuest"] = &TestingAutomationProvider::LoginAsGuest; | 1776 handler_map["LoginAsGuest"] = &TestingAutomationProvider::LoginAsGuest; |
| 1777 handler_map["StartLogin"] = &TestingAutomationProvider::StartLogin; |
1777 handler_map["AddLoginEventObserver"] = | 1778 handler_map["AddLoginEventObserver"] = |
1778 &TestingAutomationProvider::AddLoginEventObserver; | 1779 &TestingAutomationProvider::AddLoginEventObserver; |
1779 handler_map["SignOut"] = &TestingAutomationProvider::SignOut; | 1780 handler_map["SignOut"] = &TestingAutomationProvider::SignOut; |
1780 | 1781 |
1781 handler_map["LockScreen"] = &TestingAutomationProvider::LockScreen; | 1782 handler_map["LockScreen"] = &TestingAutomationProvider::LockScreen; |
1782 handler_map["UnlockScreen"] = &TestingAutomationProvider::UnlockScreen; | 1783 handler_map["UnlockScreen"] = &TestingAutomationProvider::UnlockScreen; |
1783 handler_map["SignoutInScreenLocker"] = | 1784 handler_map["SignoutInScreenLocker"] = |
1784 &TestingAutomationProvider::SignoutInScreenLocker; | 1785 &TestingAutomationProvider::SignoutInScreenLocker; |
1785 | 1786 |
1786 handler_map["GetBatteryInfo"] = &TestingAutomationProvider::GetBatteryInfo; | 1787 handler_map["GetBatteryInfo"] = &TestingAutomationProvider::GetBatteryInfo; |
(...skipping 4855 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6642 } | 6643 } |
6643 | 6644 |
6644 void TestingAutomationProvider::EnsureTabSelected(Browser* browser, | 6645 void TestingAutomationProvider::EnsureTabSelected(Browser* browser, |
6645 WebContents* tab) { | 6646 WebContents* tab) { |
6646 if (browser->GetSelectedWebContents() != tab || | 6647 if (browser->GetSelectedWebContents() != tab || |
6647 browser != BrowserList::GetLastActive()) { | 6648 browser != BrowserList::GetLastActive()) { |
6648 browser->ActivateTabAt(browser->GetIndexOfController(&tab->GetController()), | 6649 browser->ActivateTabAt(browser->GetIndexOfController(&tab->GetController()), |
6649 true /* user_gesture */); | 6650 true /* user_gesture */); |
6650 } | 6651 } |
6651 } | 6652 } |
OLD | NEW |