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/media_delegate.h"
11 #include "ash/shell_delegate.h"
12 #include "base/compiler_specific.h"
13 #include "base/memory/scoped_ptr.h"
16 class KeyboardControllerProxy;
22 class TestSessionStateDelegate;
24 class TestShellDelegate : public ShellDelegate {
27 virtual ~TestShellDelegate();
29 void set_multi_profiles_enabled(bool multi_profiles_enabled) {
30 multi_profiles_enabled_ = multi_profiles_enabled;
33 // Overridden from ShellDelegate:
34 virtual bool IsFirstRunAfterBoot() const OVERRIDE;
35 virtual bool IsIncognitoAllowed() const OVERRIDE;
36 virtual bool IsMultiProfilesEnabled() const OVERRIDE;
37 virtual bool IsRunningInForcedAppMode() const OVERRIDE;
38 virtual bool IsMultiAccountEnabled() const OVERRIDE;
39 virtual void PreInit() OVERRIDE;
40 virtual void PreShutdown() OVERRIDE;
41 virtual void Exit() OVERRIDE;
42 virtual keyboard::KeyboardControllerProxy*
43 CreateKeyboardControllerProxy() OVERRIDE;
44 virtual void VirtualKeyboardActivated(bool activated) OVERRIDE;
45 virtual void AddVirtualKeyboardStateObserver(
46 VirtualKeyboardStateObserver* observer) OVERRIDE;
47 virtual void RemoveVirtualKeyboardStateObserver(
48 VirtualKeyboardStateObserver* observer) OVERRIDE;
49 virtual content::BrowserContext* GetActiveBrowserContext() OVERRIDE;
50 virtual app_list::AppListViewDelegate* CreateAppListViewDelegate() OVERRIDE;
51 virtual ShelfDelegate* CreateShelfDelegate(ShelfModel* model) OVERRIDE;
52 virtual SystemTrayDelegate* CreateSystemTrayDelegate() OVERRIDE;
53 virtual UserWallpaperDelegate* CreateUserWallpaperDelegate() OVERRIDE;
54 virtual SessionStateDelegate* CreateSessionStateDelegate() OVERRIDE;
55 virtual AccessibilityDelegate* CreateAccessibilityDelegate() OVERRIDE;
56 virtual NewWindowDelegate* CreateNewWindowDelegate() OVERRIDE;
57 virtual MediaDelegate* CreateMediaDelegate() OVERRIDE;
58 virtual ui::MenuModel* CreateContextMenu(
60 ash::ShelfItemDelegate* item_delegate,
61 ash::ShelfItem* item) OVERRIDE;
62 virtual GPUSupport* CreateGPUSupport() OVERRIDE;
63 virtual base::string16 GetProductName() const OVERRIDE;
65 int num_exit_requests() const { return num_exit_requests_; }
67 TestSessionStateDelegate* test_session_state_delegate() {
68 return test_session_state_delegate_;
71 void SetMediaCaptureState(MediaCaptureState state);
74 int num_exit_requests_;
75 bool multi_profiles_enabled_;
77 scoped_ptr<content::BrowserContext> active_browser_context_;
79 TestSessionStateDelegate* test_session_state_delegate_; // Not owned.
81 DISALLOW_COPY_AND_ASSIGN(TestShellDelegate);
87 #endif // ASH_TEST_TEST_SHELL_DELEGATE_H_