Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(304)

Side by Side Diff: chrome/browser/automation/testing_automation_provider.cc

Issue 10533038: Switch back to the old method of launching the login flow while keeping some of the benefits of the… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Addressed Nirnimesh's comments and fixed chromeos_login.py to work with these changes. Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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
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["SubmitLoginForm"] = &TestingAutomationProvider::SubmitLoginForm;
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
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 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698