| 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/shelf/shelf_controller.h" | 5 #include "ash/shelf/shelf_controller.h" |
| 6 | 6 |
| 7 #include "ash/public/interfaces/shelf.mojom.h" | 7 #include "ash/public/interfaces/shelf.mojom.h" |
| 8 #include "ash/root_window_controller.h" | 8 #include "ash/root_window_controller.h" |
| 9 #include "ash/shelf/app_list_shelf_item_delegate.h" | 9 #include "ash/shelf/app_list_shelf_item_delegate.h" |
| 10 #include "ash/shelf/wm_shelf.h" | 10 #include "ash/shelf/wm_shelf.h" |
| 11 #include "ash/shell.h" | 11 #include "ash/shell.h" |
| 12 #include "ash/wm_shell.h" | |
| 13 #include "ash/wm_window.h" | 12 #include "ash/wm_window.h" |
| 14 #include "base/strings/utf_string_conversions.h" | 13 #include "base/strings/utf_string_conversions.h" |
| 15 #include "ui/base/models/simple_menu_model.h" | 14 #include "ui/base/models/simple_menu_model.h" |
| 16 #include "ui/base/resource/resource_bundle.h" | 15 #include "ui/base/resource/resource_bundle.h" |
| 17 #include "ui/display/display.h" | 16 #include "ui/display/display.h" |
| 18 #include "ui/display/screen.h" | 17 #include "ui/display/screen.h" |
| 19 #include "ui/gfx/image/image_skia.h" | 18 #include "ui/gfx/image/image_skia.h" |
| 20 #include "ui/resources/grit/ui_resources.h" | 19 #include "ui/resources/grit/ui_resources.h" |
| 21 | 20 |
| 22 namespace ash { | 21 namespace ash { |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 127 return; | 126 return; |
| 128 ShelfID shelf_id = app_id_to_shelf_id_[app_id]; | 127 ShelfID shelf_id = app_id_to_shelf_id_[app_id]; |
| 129 int index = model_.ItemIndexByID(shelf_id); | 128 int index = model_.ItemIndexByID(shelf_id); |
| 130 DCHECK_GE(index, 0); | 129 DCHECK_GE(index, 0); |
| 131 ShelfItem item = *model_.ItemByID(shelf_id); | 130 ShelfItem item = *model_.ItemByID(shelf_id); |
| 132 item.image = GetShelfIconFromBitmap(image); | 131 item.image = GetShelfIconFromBitmap(image); |
| 133 model_.Set(index, item); | 132 model_.Set(index, item); |
| 134 } | 133 } |
| 135 | 134 |
| 136 } // namespace ash | 135 } // namespace ash |
| OLD | NEW |