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

Side by Side Diff: ios/chrome/test/app/tab_test_util.h

Issue 2580333003: Upstream Chrome on iOS source code [10/11]. (Closed)
Patch Set: Created 4 years 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
« no previous file with comments | « ios/chrome/test/app/sync_test_util.mm ('k') | ios/chrome/test/app/tab_test_util.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef IOS_CHROME_TEST_APP_TAB_TEST_UTIL_H_
6 #define IOS_CHROME_TEST_APP_TAB_TEST_UTIL_H_
7
8 #import <Foundation/Foundation.h>
9
10 @class FormInputAccessoryViewController;
11 @class Tab;
12 @class TabView;
13
14 namespace chrome_test_util {
15
16 // Opens a new tab, and does not wait for animations to complete.
17 void OpenNewTab();
18
19 // Opens a new incognito tab, and does not wait for animations to complete.
20 void OpenNewIncognitoTab();
21
22 // Returns YES if the browser is in incognito mode, and NO otherwise.
23 BOOL IsIncognitoMode();
24
25 // Gets current tab.
26 Tab* GetCurrentTab();
27
28 // Gets next tab and returns nil if less than two tabs are open.
29 Tab* GetNextTab();
30
31 // Closes current tab.
32 void CloseCurrentTab();
33
34 // Closes tab with the given index in current mode (incognito or normal).
35 void CloseTabAtIndex(NSUInteger index);
36
37 // Closes all tabs in the current mode (incognito or normal), and does not wait
38 // for the UI to complete. If current mode is Incognito, mode will be switched
39 // normal after closing all tabs.
40 void CloseAllTabsInCurrentMode();
41
42 // Closes all tabs in the all modes (incognito and normal), and does not wait
43 // for the UI to complete.
44 // If current mode is Incognito, mode will be switched to normal after closing
45 // the incognito tabs.
46 void CloseAllTabs();
47
48 // Selects tab with given index in current mode (incognito or normal).
49 void SelectTabAtIndexInCurrentMode(NSUInteger index);
50
51 // Returns the number of main tabs.
52 NSUInteger GetMainTabCount();
53
54 // Returns the number of incognito tabs.
55 NSUInteger GetIncognitoTabCount();
56
57 // Resets the tab usage recorder on current mode. Return YES on success.
58 BOOL ResetTabUsageRecorder();
59
60 // Sets the normal tabs as 'cold start' tabs. Return YES on success.
61 BOOL SetCurrentTabsToBeColdStartTabs();
62
63 // Simulates a backgrounding. Return YES on success.
64 BOOL SimulateTabsBackgrounding();
65
66 // Evicts the tabs associated with the non-current browser mode.
67 void EvictOtherTabModelTabs();
68
69 // Closes all incognito tabs.
70 void CloseAllIncognitoTabs();
71
72 // Gets the tabview for tab.
73 TabView* GetTabViewForTab(Tab* tab);
74
75 // Returns the number of main tabs currently evicted.
76 NSUInteger GetEvictedMainTabCount();
77
78 // Returns the current tab's input accessory view controller.
79 FormInputAccessoryViewController* GetInputAccessoryViewController();
80
81 } // namespace chrome_test_util
82
83 #endif // IOS_CHROME_TEST_APP_TAB_TEST_UTIL_H_
OLDNEW
« no previous file with comments | « ios/chrome/test/app/sync_test_util.mm ('k') | ios/chrome/test/app/tab_test_util.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698