OLD | NEW |
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 ASH_SHELL_H_ | 5 #ifndef ASH_SHELL_H_ |
6 #define ASH_SHELL_H_ | 6 #define ASH_SHELL_H_ |
7 | 7 |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
11 #include "ash/ash_export.h" | 11 #include "ash/ash_export.h" |
12 #include "ash/shelf_types.h" | 12 #include "ash/shelf/shelf_types.h" |
13 #include "ash/system/user/login_status.h" | 13 #include "ash/system/user/login_status.h" |
14 #include "ash/wm/system_modal_container_event_filter_delegate.h" | 14 #include "ash/wm/system_modal_container_event_filter_delegate.h" |
15 #include "base/basictypes.h" | 15 #include "base/basictypes.h" |
16 #include "base/compiler_specific.h" | 16 #include "base/compiler_specific.h" |
17 #include "base/gtest_prod_util.h" | 17 #include "base/gtest_prod_util.h" |
18 #include "base/memory/scoped_ptr.h" | 18 #include "base/memory/scoped_ptr.h" |
19 #include "base/observer_list.h" | 19 #include "base/observer_list.h" |
20 #include "ui/aura/client/activation_change_observer.h" | 20 #include "ui/aura/client/activation_change_observer.h" |
21 #include "ui/base/events/event_target.h" | 21 #include "ui/base/events/event_target.h" |
22 #include "ui/gfx/insets.h" | 22 #include "ui/gfx/insets.h" |
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
436 } | 436 } |
437 #endif // defined(OS_CHROMEOS) | 437 #endif // defined(OS_CHROMEOS) |
438 | 438 |
439 RootWindowHostFactory* root_window_host_factory() { | 439 RootWindowHostFactory* root_window_host_factory() { |
440 return root_window_host_factory_.get(); | 440 return root_window_host_factory_.get(); |
441 } | 441 } |
442 | 442 |
443 // MessageCenter is a global list of currently displayed notifications. | 443 // MessageCenter is a global list of currently displayed notifications. |
444 message_center::MessageCenter* message_center(); | 444 message_center::MessageCenter* message_center(); |
445 | 445 |
| 446 LauncherModel* launcher_model() { |
| 447 return launcher_model_.get(); |
| 448 } |
| 449 |
| 450 // Returns the launcher delegate, creating if necesary. |
| 451 LauncherDelegate* GetLauncherDelegate(); |
| 452 |
446 private: | 453 private: |
447 FRIEND_TEST_ALL_PREFIXES(ExtendedDesktopTest, TestCursor); | 454 FRIEND_TEST_ALL_PREFIXES(ExtendedDesktopTest, TestCursor); |
448 FRIEND_TEST_ALL_PREFIXES(WindowManagerTest, MouseEventCursors); | 455 FRIEND_TEST_ALL_PREFIXES(WindowManagerTest, MouseEventCursors); |
449 FRIEND_TEST_ALL_PREFIXES(WindowManagerTest, TransformActivate); | 456 FRIEND_TEST_ALL_PREFIXES(WindowManagerTest, TransformActivate); |
450 friend class internal::RootWindowController; | 457 friend class internal::RootWindowController; |
451 friend class test::ShellTestApi; | 458 friend class test::ShellTestApi; |
452 friend class shell::WindowWatcher; | 459 friend class shell::WindowWatcher; |
453 | 460 |
454 typedef std::pair<aura::Window*, gfx::Rect> WindowAndBoundsPair; | 461 typedef std::pair<aura::Window*, gfx::Rect> WindowAndBoundsPair; |
455 | 462 |
456 explicit Shell(ShellDelegate* delegate); | 463 explicit Shell(ShellDelegate* delegate); |
457 virtual ~Shell(); | 464 virtual ~Shell(); |
458 | 465 |
459 void Init(); | 466 void Init(); |
460 | 467 |
461 LauncherModel* launcher_model() { | |
462 return launcher_model_.get(); | |
463 } | |
464 | |
465 // Returns the launcher delegate, creating if necesary. | |
466 LauncherDelegate* GetLauncherDelegate(); | |
467 | |
468 // Initializes the root window and root window controller so that it | 468 // Initializes the root window and root window controller so that it |
469 // can host browser windows. | 469 // can host browser windows. |
470 void InitRootWindowController(internal::RootWindowController* root); | 470 void InitRootWindowController(internal::RootWindowController* root); |
471 | 471 |
472 // Initializes the layout managers and event filters specific for | 472 // Initializes the layout managers and event filters specific for |
473 // primary display. | 473 // primary display. |
474 void InitLayoutManagersForPrimaryDisplay( | 474 void InitLayoutManagersForPrimaryDisplay( |
475 internal::RootWindowController* root_window_controller); | 475 internal::RootWindowController* root_window_controller); |
476 | 476 |
477 // ash::internal::SystemModalContainerEventFilterDelegate overrides: | 477 // ash::internal::SystemModalContainerEventFilterDelegate overrides: |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
598 | 598 |
599 // For testing only: simulate that a modal window is open | 599 // For testing only: simulate that a modal window is open |
600 bool simulate_modal_window_open_for_testing_; | 600 bool simulate_modal_window_open_for_testing_; |
601 | 601 |
602 DISALLOW_COPY_AND_ASSIGN(Shell); | 602 DISALLOW_COPY_AND_ASSIGN(Shell); |
603 }; | 603 }; |
604 | 604 |
605 } // namespace ash | 605 } // namespace ash |
606 | 606 |
607 #endif // ASH_SHELL_H_ | 607 #endif // ASH_SHELL_H_ |
OLD | NEW |