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

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

Issue 6277020: keyboard: Update the visibility after tab-switch. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: build fix Created 9 years, 10 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 <vector> 7 #include <vector>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 594 matching lines...) Expand 10 before | Expand all | Expand 10 after
605 } 605 }
606 606
607 void CrashTab(TabContents* tab) { 607 void CrashTab(TabContents* tab) {
608 RenderProcessHost* rph = tab->render_view_host()->process(); 608 RenderProcessHost* rph = tab->render_view_host()->process();
609 base::KillProcess(rph->GetHandle(), 0, false); 609 base::KillProcess(rph->GetHandle(), 0, false);
610 TestNotificationObserver observer; 610 TestNotificationObserver observer;
611 RegisterAndWait(&observer, NotificationType::RENDERER_PROCESS_CLOSED, 611 RegisterAndWait(&observer, NotificationType::RENDERER_PROCESS_CLOSED,
612 Source<RenderProcessHost>(rph)); 612 Source<RenderProcessHost>(rph));
613 } 613 }
614 614
615 void WaitForFocusChange(RenderViewHost* rvh) { 615 void WaitForFocusChange(TabContents* tab_contents) {
616 TestNotificationObserver observer; 616 TestNotificationObserver observer;
617 RegisterAndWait(&observer, NotificationType::FOCUS_CHANGED_IN_PAGE, 617 RegisterAndWait(&observer, NotificationType::FOCUS_CHANGED_IN_PAGE,
618 Source<RenderViewHost>(rvh)); 618 Source<TabContents>(tab_contents));
619 } 619 }
620 620
621 void WaitForFocusInBrowser(Browser* browser) { 621 void WaitForFocusInBrowser(Browser* browser) {
622 TestNotificationObserver observer; 622 TestNotificationObserver observer;
623 RegisterAndWait(&observer, NotificationType::FOCUS_RETURNED_TO_BROWSER, 623 RegisterAndWait(&observer, NotificationType::FOCUS_RETURNED_TO_BROWSER,
624 Source<Browser>(browser)); 624 Source<Browser>(browser));
625 } 625 }
626 626
627 int FindInPage(TabContents* tab_contents, const string16& search_string, 627 int FindInPage(TabContents* tab_contents, const string16& search_string,
628 bool forward, bool match_case, int* ordinal) { 628 bool forward, bool match_case, int* ordinal) {
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
1019 return taker.TakeRenderWidgetSnapshot(rwh, page_size, page_size, bitmap); 1019 return taker.TakeRenderWidgetSnapshot(rwh, page_size, page_size, bitmap);
1020 } 1020 }
1021 1021
1022 bool TakeEntirePageSnapshot(RenderViewHost* rvh, SkBitmap* bitmap) { 1022 bool TakeEntirePageSnapshot(RenderViewHost* rvh, SkBitmap* bitmap) {
1023 DCHECK(bitmap); 1023 DCHECK(bitmap);
1024 SnapshotTaker taker; 1024 SnapshotTaker taker;
1025 return taker.TakeEntirePageSnapshot(rvh, bitmap); 1025 return taker.TakeEntirePageSnapshot(rvh, bitmap);
1026 } 1026 }
1027 1027
1028 } // namespace ui_test_utils 1028 } // 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