| OLD | NEW |
| (Empty) |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef ASH_COMMON_SHELF_SHELF_ITEM_TYPES_H_ | |
| 6 #define ASH_COMMON_SHELF_SHELF_ITEM_TYPES_H_ | |
| 7 | |
| 8 // TODO(msw): Rename these files to shelf_item.*; audit users. | |
| 9 | |
| 10 #include <string> | |
| 11 #include <vector> | |
| 12 | |
| 13 #include "ash/ash_export.h" | |
| 14 #include "ash/public/cpp/shelf_types.h" | |
| 15 #include "base/strings/string16.h" | |
| 16 #include "ui/gfx/image/image_skia.h" | |
| 17 | |
| 18 namespace ash { | |
| 19 | |
| 20 struct ASH_EXPORT ShelfItem { | |
| 21 ShelfItem(); | |
| 22 ShelfItem(const ShelfItem& shelf_item); | |
| 23 ~ShelfItem(); | |
| 24 | |
| 25 ShelfItemType type = TYPE_UNDEFINED; | |
| 26 | |
| 27 // Image to display in the shelf. | |
| 28 gfx::ImageSkia image; | |
| 29 | |
| 30 // Assigned by the model when the item is added. | |
| 31 ShelfID id = kInvalidShelfID; | |
| 32 | |
| 33 // Running status. | |
| 34 ShelfItemStatus status = STATUS_CLOSED; | |
| 35 | |
| 36 // The application id for this shelf item; only populated for some items. | |
| 37 std::string app_id; | |
| 38 | |
| 39 // The title to display for tooltips, etc. | |
| 40 base::string16 title; | |
| 41 | |
| 42 // Whether the tooltip should be shown on hover; generally true. | |
| 43 bool shows_tooltip = true; | |
| 44 | |
| 45 // Whether the item is pinned by a policy preference (ie. user cannot un-pin). | |
| 46 bool pinned_by_policy = false; | |
| 47 }; | |
| 48 | |
| 49 typedef std::vector<ShelfItem> ShelfItems; | |
| 50 | |
| 51 } // namespace ash | |
| 52 | |
| 53 #endif // ASH_COMMON_SHELF_SHELF_ITEM_TYPES_H_ | |
| OLD | NEW |