| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/aura/wm_shelf_aura.h" | 5 #include "ash/aura/wm_shelf_aura.h" |
| 6 | 6 |
| 7 #include "ash/aura/wm_window_aura.h" | 7 #include "ash/aura/wm_window_aura.h" |
| 8 #include "ash/common/shelf/shelf_layout_manager.h" |
| 8 #include "ash/shelf/dimmer_view.h" | 9 #include "ash/shelf/dimmer_view.h" |
| 9 #include "ash/shelf/shelf_bezel_event_handler.h" | 10 #include "ash/shelf/shelf_bezel_event_handler.h" |
| 10 #include "ash/shelf/shelf_layout_manager.h" | |
| 11 #include "ash/shell.h" | 11 #include "ash/shell.h" |
| 12 | 12 |
| 13 namespace ash { | 13 namespace ash { |
| 14 | 14 |
| 15 // WmShelfAura::AutoHideEventHandler ------------------------------------------- | 15 // WmShelfAura::AutoHideEventHandler ------------------------------------------- |
| 16 | 16 |
| 17 // Forwards mouse and gesture events to ShelfLayoutManager for auto-hide. | 17 // Forwards mouse and gesture events to ShelfLayoutManager for auto-hide. |
| 18 // TODO(mash): Add similar event handling support for mash. | 18 // TODO(mash): Add similar event handling support for mash. |
| 19 class WmShelfAura::AutoHideEventHandler : public ui::EventHandler { | 19 class WmShelfAura::AutoHideEventHandler : public ui::EventHandler { |
| 20 public: | 20 public: |
| (...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 WmShelf::WillChangeVisibilityState(new_state); | 67 WmShelf::WillChangeVisibilityState(new_state); |
| 68 if (new_state != SHELF_AUTO_HIDE) { | 68 if (new_state != SHELF_AUTO_HIDE) { |
| 69 auto_hide_event_handler_.reset(); | 69 auto_hide_event_handler_.reset(); |
| 70 } else if (!auto_hide_event_handler_) { | 70 } else if (!auto_hide_event_handler_) { |
| 71 auto_hide_event_handler_.reset( | 71 auto_hide_event_handler_.reset( |
| 72 new AutoHideEventHandler(shelf_layout_manager())); | 72 new AutoHideEventHandler(shelf_layout_manager())); |
| 73 } | 73 } |
| 74 } | 74 } |
| 75 | 75 |
| 76 } // namespace ash | 76 } // namespace ash |
| OLD | NEW |