| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/common/shelf/shelf_window_watcher_item_delegate.h" | 5 #include "ash/common/shelf/shelf_window_watcher_item_delegate.h" |
| 6 | 6 |
| 7 #include "ash/common/shelf/shelf_controller.h" | 7 #include "ash/common/shelf/shelf_controller.h" |
| 8 #include "ash/common/shelf/shelf_model.h" | 8 #include "ash/common/shelf/shelf_model.h" |
| 9 #include "ash/common/wm/window_state.h" | 9 #include "ash/common/wm/window_state.h" |
| 10 #include "ash/common/wm_shell.h" | 10 #include "ash/common/wm_shell.h" |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 window_->Animate(::wm::WINDOW_ANIMATION_TYPE_BOUNCE); | 48 window_->Animate(::wm::WINDOW_ANIMATION_TYPE_BOUNCE); |
| 49 return kNoAction; | 49 return kNoAction; |
| 50 } | 50 } |
| 51 window_->Minimize(); | 51 window_->Minimize(); |
| 52 return kExistingWindowMinimized; | 52 return kExistingWindowMinimized; |
| 53 } | 53 } |
| 54 window_->Activate(); | 54 window_->Activate(); |
| 55 return kExistingWindowActivated; | 55 return kExistingWindowActivated; |
| 56 } | 56 } |
| 57 | 57 |
| 58 ui::SimpleMenuModel* ShelfWindowWatcherItemDelegate::CreateApplicationMenu( | 58 ShelfAppMenuItemList ShelfWindowWatcherItemDelegate::GetAppMenuItems( |
| 59 int event_flags) { | 59 int event_flags) { |
| 60 return nullptr; | 60 // Return an empty item list to avoid showing an application menu. |
| 61 return ShelfAppMenuItemList(); |
| 61 } | 62 } |
| 62 | 63 |
| 63 void ShelfWindowWatcherItemDelegate::Close() { | 64 void ShelfWindowWatcherItemDelegate::Close() { |
| 64 window_->CloseWidget(); | 65 window_->CloseWidget(); |
| 65 } | 66 } |
| 66 | 67 |
| 67 } // namespace ash | 68 } // namespace ash |
| OLD | NEW |