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
3 // found in the LICENSE file.
5 #ifndef ASH_TEST_TEST_SHELL_DELEGATE_H_
6 #define ASH_TEST_TEST_SHELL_DELEGATE_H_
10 #include "ash/shell_delegate.h"
11 #include "base/compiler_specific.h"
12 #include "base/memory/scoped_ptr.h"
15 class KeyboardControllerProxy
;
21 class TestSessionStateDelegate
;
23 class TestShellDelegate
: public ShellDelegate
{
26 virtual ~TestShellDelegate();
28 void set_multi_profiles_enabled(bool multi_profiles_enabled
) {
29 multi_profiles_enabled_
= multi_profiles_enabled
;
32 // Overridden from ShellDelegate:
33 virtual bool IsFirstRunAfterBoot() const OVERRIDE
;
34 virtual bool IsIncognitoAllowed() const OVERRIDE
;
35 virtual bool IsMultiProfilesEnabled() const OVERRIDE
;
36 virtual bool IsRunningInForcedAppMode() const OVERRIDE
;
37 virtual void PreInit() OVERRIDE
;
38 virtual void Shutdown() OVERRIDE
;
39 virtual void Exit() OVERRIDE
;
40 virtual keyboard::KeyboardControllerProxy
*
41 CreateKeyboardControllerProxy() OVERRIDE
;
42 virtual content::BrowserContext
* GetCurrentBrowserContext() OVERRIDE
;
43 virtual app_list::AppListViewDelegate
* CreateAppListViewDelegate() OVERRIDE
;
44 virtual ShelfDelegate
* CreateShelfDelegate(ShelfModel
* model
) OVERRIDE
;
45 virtual SystemTrayDelegate
* CreateSystemTrayDelegate() OVERRIDE
;
46 virtual UserWallpaperDelegate
* CreateUserWallpaperDelegate() OVERRIDE
;
47 virtual CapsLockDelegate
* CreateCapsLockDelegate() OVERRIDE
;
48 virtual SessionStateDelegate
* CreateSessionStateDelegate() OVERRIDE
;
49 virtual AccessibilityDelegate
* CreateAccessibilityDelegate() OVERRIDE
;
50 virtual NewWindowDelegate
* CreateNewWindowDelegate() OVERRIDE
;
51 virtual MediaDelegate
* CreateMediaDelegate() OVERRIDE
;
52 virtual aura::client::UserActionClient
* CreateUserActionClient() OVERRIDE
;
53 virtual void RecordUserMetricsAction(UserMetricsAction action
) OVERRIDE
;
54 virtual ui::MenuModel
* CreateContextMenu(aura::Window
* root
) OVERRIDE
;
55 virtual RootWindowHostFactory
* CreateRootWindowHostFactory() OVERRIDE
;
56 virtual base::string16
GetProductName() const OVERRIDE
;
58 int num_exit_requests() const { return num_exit_requests_
; }
60 TestSessionStateDelegate
* test_session_state_delegate();
63 int num_exit_requests_
;
64 bool multi_profiles_enabled_
;
66 scoped_ptr
<content::BrowserContext
> current_browser_context_
;
68 TestSessionStateDelegate
* test_session_state_delegate_
; // Not owned.
70 DISALLOW_COPY_AND_ASSIGN(TestShellDelegate
);
76 #endif // ASH_TEST_TEST_SHELL_DELEGATE_H_