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 #include "ash/shell.h" | 5 #include "ash/shell.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "ash/accelerators/focus_manager_factory.h" | 10 #include "ash/accelerators/focus_manager_factory.h" |
(...skipping 679 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
690 void Shell::SetShelfAutoHideBehavior(ShelfAutoHideBehavior behavior, | 690 void Shell::SetShelfAutoHideBehavior(ShelfAutoHideBehavior behavior, |
691 aura::RootWindow* root_window) { | 691 aura::RootWindow* root_window) { |
692 GetRootWindowController(root_window)->SetShelfAutoHideBehavior(behavior); | 692 GetRootWindowController(root_window)->SetShelfAutoHideBehavior(behavior); |
693 } | 693 } |
694 | 694 |
695 ShelfAutoHideBehavior Shell::GetShelfAutoHideBehavior( | 695 ShelfAutoHideBehavior Shell::GetShelfAutoHideBehavior( |
696 aura::RootWindow* root_window) const { | 696 aura::RootWindow* root_window) const { |
697 return GetRootWindowController(root_window)->GetShelfAutoHideBehavior(); | 697 return GetRootWindowController(root_window)->GetShelfAutoHideBehavior(); |
698 } | 698 } |
699 | 699 |
700 bool Shell::IsShelfAutoHideMenuHideChecked(aura::RootWindow* root_window) { | |
701 return GetRootWindowController(root_window)->GetShelfAutoHideBehavior() == | |
702 ash::SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS; | |
703 } | |
704 | |
705 ShelfAutoHideBehavior Shell::GetToggledShelfAutoHideBehavior( | |
706 aura::RootWindow* root_window) { | |
707 return GetRootWindowController(root_window)-> | |
708 GetToggledShelfAutoHideBehavior(); | |
709 } | |
710 | |
711 void Shell::SetShelfAlignment(ShelfAlignment alignment, | 700 void Shell::SetShelfAlignment(ShelfAlignment alignment, |
712 aura::RootWindow* root_window) { | 701 aura::RootWindow* root_window) { |
713 if (GetRootWindowController(root_window)->SetShelfAlignment(alignment)) | 702 if (GetRootWindowController(root_window)->SetShelfAlignment(alignment)) |
714 FOR_EACH_OBSERVER(ShellObserver, observers_, OnShelfAlignmentChanged()); | 703 FOR_EACH_OBSERVER(ShellObserver, observers_, OnShelfAlignmentChanged()); |
715 } | 704 } |
716 | 705 |
717 ShelfAlignment Shell::GetShelfAlignment(aura::RootWindow* root_window) { | 706 ShelfAlignment Shell::GetShelfAlignment(aura::RootWindow* root_window) { |
718 return GetRootWindowController(root_window)->GetShelfAlignment(); | 707 return GetRootWindowController(root_window)->GetShelfAlignment(); |
719 } | 708 } |
720 | 709 |
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
863 | 852 |
864 bool Shell::CanAcceptEvents() { | 853 bool Shell::CanAcceptEvents() { |
865 return true; | 854 return true; |
866 } | 855 } |
867 | 856 |
868 ui::EventTarget* Shell::GetParentTarget() { | 857 ui::EventTarget* Shell::GetParentTarget() { |
869 return NULL; | 858 return NULL; |
870 } | 859 } |
871 | 860 |
872 } // namespace ash | 861 } // namespace ash |
OLD | NEW |