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

Side by Side Diff: chrome/test/base/browser_with_test_window_test.h

Issue 273073002: Changes code using Compositor to pass in ContextFactory (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix tooltip on chromeos Created 6 years, 7 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 #ifndef CHROME_TEST_BASE_BROWSER_WITH_TEST_WINDOW_TEST_H_ 5 #ifndef CHROME_TEST_BASE_BROWSER_WITH_TEST_WINDOW_TEST_H_
6 #define CHROME_TEST_BASE_BROWSER_WITH_TEST_WINDOW_TEST_H_ 6 #define CHROME_TEST_BASE_BROWSER_WITH_TEST_WINDOW_TEST_H_
7 7
8 #include "base/at_exit.h" 8 #include "base/at_exit.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "chrome/browser/ui/browser.h" 10 #include "chrome/browser/ui/browser.h"
(...skipping 23 matching lines...) Expand all
34 } 34 }
35 } 35 }
36 #endif 36 #endif
37 37
38 #if defined(USE_AURA) 38 #if defined(USE_AURA)
39 namespace aura { 39 namespace aura {
40 namespace test { 40 namespace test {
41 class AuraTestHelper; 41 class AuraTestHelper;
42 } 42 }
43 } 43 }
44 namespace ui {
45 class ContextFactory;
46 }
44 #endif 47 #endif
45 48
46 #if defined(TOOLKIT_VIEWS) 49 #if defined(TOOLKIT_VIEWS)
47 namespace views { 50 namespace views {
48 class ViewsDelegate; 51 class ViewsDelegate;
49 } 52 }
50 #endif 53 #endif
51 54
52 namespace content { 55 namespace content {
53 class NavigationController; 56 class NavigationController;
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 virtual Browser* CreateBrowser(Profile* profile, 157 virtual Browser* CreateBrowser(Profile* profile,
155 Browser::Type browser_type, 158 Browser::Type browser_type,
156 bool hosted_app, 159 bool hosted_app,
157 chrome::HostDesktopType host_desktop_type, 160 chrome::HostDesktopType host_desktop_type,
158 BrowserWindow* browser_window); 161 BrowserWindow* browser_window);
159 162
160 private: 163 private:
161 #if !defined(OS_CHROMEOS) && defined(TOOLKIT_VIEWS) 164 #if !defined(OS_CHROMEOS) && defined(TOOLKIT_VIEWS)
162 // Creates the ViewsDelegate to use, may be overriden to create a different 165 // Creates the ViewsDelegate to use, may be overriden to create a different
163 // ViewsDelegate. 166 // ViewsDelegate.
164 views::ViewsDelegate* CreateViewsDelegate(); 167 views::ViewsDelegate* CreateViewsDelegate(
168 ui::ContextFactory* context_factory);
165 #endif 169 #endif
166 170
167 // We need to create a MessageLoop, otherwise a bunch of things fails. 171 // We need to create a MessageLoop, otherwise a bunch of things fails.
168 content::TestBrowserThreadBundle thread_bundle_; 172 content::TestBrowserThreadBundle thread_bundle_;
169 base::ShadowingAtExitManager at_exit_manager_; 173 base::ShadowingAtExitManager at_exit_manager_;
170 174
171 #if defined(OS_CHROMEOS) 175 #if defined(OS_CHROMEOS)
172 chromeos::ScopedTestDeviceSettingsService test_device_settings_service_; 176 chromeos::ScopedTestDeviceSettingsService test_device_settings_service_;
173 chromeos::ScopedTestCrosSettings test_cros_settings_; 177 chromeos::ScopedTestCrosSettings test_cros_settings_;
174 chromeos::ScopedTestUserManager test_user_manager_; 178 chromeos::ScopedTestUserManager test_user_manager_;
175 #endif 179 #endif
176 180
177 // The profile will automatically be destroyed by TearDown using the 181 // The profile will automatically be destroyed by TearDown using the
178 // |DestroyProfile()| function - which can be overwritten by derived testing 182 // |DestroyProfile()| function - which can be overwritten by derived testing
179 // frameworks. 183 // frameworks.
180 TestingProfile* profile_; 184 TestingProfile* profile_;
181 scoped_ptr<BrowserWindow> window_; // Usually a TestBrowserWindow. 185 scoped_ptr<BrowserWindow> window_; // Usually a TestBrowserWindow.
182 scoped_ptr<Browser> browser_; 186 scoped_ptr<Browser> browser_;
183 187
184 // The existence of this object enables tests via 188 // The existence of this object enables tests via
185 // RenderViewHostTester. 189 // RenderViewHostTester.
186 content::RenderViewHostTestEnabler rvh_test_enabler_; 190 content::RenderViewHostTestEnabler rvh_test_enabler_;
187 191
188 #if defined(USE_ASH) 192 #if defined(OS_CHROMEOS)
189 scoped_ptr<ash::test::AshTestHelper> ash_test_helper_; 193 scoped_ptr<ash::test::AshTestHelper> ash_test_helper_;
190 #endif 194 #elif defined(USE_AURA)
191 #if defined(USE_AURA)
192 scoped_ptr<aura::test::AuraTestHelper> aura_test_helper_; 195 scoped_ptr<aura::test::AuraTestHelper> aura_test_helper_;
193 #endif 196 #endif
194 197
195 #if defined(TOOLKIT_VIEWS) 198 #if defined(TOOLKIT_VIEWS)
196 scoped_ptr<views::ViewsDelegate> views_delegate_; 199 scoped_ptr<views::ViewsDelegate> views_delegate_;
197 #endif 200 #endif
198 201
199 #if defined(OS_WIN) 202 #if defined(OS_WIN)
200 ui::ScopedOleInitializer ole_initializer_; 203 ui::ScopedOleInitializer ole_initializer_;
201 #endif 204 #endif
202 205
203 // The type of browser to create (tabbed or popup). 206 // The type of browser to create (tabbed or popup).
204 Browser::Type browser_type_; 207 Browser::Type browser_type_;
205 208
206 // The desktop to create the initial window on. 209 // The desktop to create the initial window on.
207 chrome::HostDesktopType host_desktop_type_; 210 chrome::HostDesktopType host_desktop_type_;
208 211
209 // Whether the browser is part of a hosted app. 212 // Whether the browser is part of a hosted app.
210 bool hosted_app_; 213 bool hosted_app_;
211 214
212 DISALLOW_COPY_AND_ASSIGN(BrowserWithTestWindowTest); 215 DISALLOW_COPY_AND_ASSIGN(BrowserWithTestWindowTest);
213 }; 216 };
214 217
215 #endif // CHROME_TEST_BASE_BROWSER_WITH_TEST_WINDOW_TEST_H_ 218 #endif // CHROME_TEST_BASE_BROWSER_WITH_TEST_WINDOW_TEST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698