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

Side by Side Diff: chrome/test/ui_test_utils.cc

Issue 210013: Making BrowserFocusTest FocusTraversal faster (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 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
« no previous file with comments | « chrome/test/ui_test_utils.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/test/ui_test_utils.h" 5 #include "chrome/test/ui_test_utils.h"
6 6
7 #include "base/json_reader.h" 7 #include "base/json_reader.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/process_util.h" 10 #include "base/process_util.h"
(...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after
412 return observer.WaitForAppModalDialog(); 412 return observer.WaitForAppModalDialog();
413 } 413 }
414 414
415 void CrashTab(TabContents* tab) { 415 void CrashTab(TabContents* tab) {
416 RenderProcessHost* rph = tab->render_view_host()->process(); 416 RenderProcessHost* rph = tab->render_view_host()->process();
417 base::KillProcess(rph->process().handle(), 0, false); 417 base::KillProcess(rph->process().handle(), 0, false);
418 SimpleNotificationObserver<RenderProcessHost> 418 SimpleNotificationObserver<RenderProcessHost>
419 crash_observer(NotificationType::RENDERER_PROCESS_CLOSED, rph); 419 crash_observer(NotificationType::RENDERER_PROCESS_CLOSED, rph);
420 } 420 }
421 421
422 void WaitForFocusChange(RenderViewHost* rvh) {
423 SimpleNotificationObserver<RenderViewHost>
424 focus_observer(NotificationType::FOCUS_CHANGED_IN_PAGE, rvh);
425 }
426
427 void WaitForFocusInBrowser(Browser* browser) {
428 SimpleNotificationObserver<Browser>
429 focus_observer(NotificationType::FOCUS_RETURNED_TO_BROWSER,
430 browser);
431 }
432
422 } // namespace ui_test_utils 433 } // namespace ui_test_utils
OLDNEW
« no previous file with comments | « chrome/test/ui_test_utils.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698