| 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 #ifndef UI_APP_LIST_VIEWS_APP_LIST_ITEM_VIEW_H_ | 5 #ifndef UI_APP_LIST_VIEWS_APP_LIST_ITEM_VIEW_H_ |
| 6 #define UI_APP_LIST_VIEWS_APP_LIST_ITEM_VIEW_H_ | 6 #define UI_APP_LIST_VIEWS_APP_LIST_ITEM_VIEW_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 void CancelContextMenu(); | 48 void CancelContextMenu(); |
| 49 | 49 |
| 50 gfx::ImageSkia GetDragImage(); | 50 gfx::ImageSkia GetDragImage(); |
| 51 void OnDragEnded(); | 51 void OnDragEnded(); |
| 52 gfx::Point GetDragImageOffset(); | 52 gfx::Point GetDragImageOffset(); |
| 53 | 53 |
| 54 void SetAsAttemptedFolderTarget(bool is_target_folder); | 54 void SetAsAttemptedFolderTarget(bool is_target_folder); |
| 55 | 55 |
| 56 AppListItem* item() const { return item_; } | 56 AppListItem* item() const { return item_; } |
| 57 | 57 |
| 58 views::ImageView* icon() const { return icon_; } |
| 59 |
| 58 const views::Label* title() const { return title_; } | 60 const views::Label* title() const { return title_; } |
| 59 | 61 |
| 60 // In a synchronous drag the item view isn't informed directly of the drag | 62 // In a synchronous drag the item view isn't informed directly of the drag |
| 61 // ending, so the runner of the drag should call this. | 63 // ending, so the runner of the drag should call this. |
| 62 void OnSyncDragEnd(); | 64 void OnSyncDragEnd(); |
| 63 | 65 |
| 64 // Returns the icon bounds relative to AppListItemView. | 66 // Returns the icon bounds relative to AppListItemView. |
| 65 const gfx::Rect& GetIconBounds() const; | 67 const gfx::Rect& GetIconBounds() const; |
| 66 | 68 |
| 67 // Sets UI state to dragging state. | 69 // Sets UI state to dragging state. |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 147 | 149 |
| 148 // A timer to defer showing drag UI when mouse is pressed. | 150 // A timer to defer showing drag UI when mouse is pressed. |
| 149 base::OneShotTimer<AppListItemView> mouse_drag_timer_; | 151 base::OneShotTimer<AppListItemView> mouse_drag_timer_; |
| 150 | 152 |
| 151 DISALLOW_COPY_AND_ASSIGN(AppListItemView); | 153 DISALLOW_COPY_AND_ASSIGN(AppListItemView); |
| 152 }; | 154 }; |
| 153 | 155 |
| 154 } // namespace app_list | 156 } // namespace app_list |
| 155 | 157 |
| 156 #endif // UI_APP_LIST_VIEWS_APP_LIST_ITEM_VIEW_H_ | 158 #endif // UI_APP_LIST_VIEWS_APP_LIST_ITEM_VIEW_H_ |
| OLD | NEW |