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_APPS_GRID_VIEW_H_ | 5 #ifndef UI_APP_LIST_VIEWS_APPS_GRID_VIEW_H_ |
6 #define UI_APP_LIST_VIEWS_APPS_GRID_VIEW_H_ | 6 #define UI_APP_LIST_VIEWS_APPS_GRID_VIEW_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 | 10 |
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
73 // view, which usually is the hosting AppListView. |pagination_model| is | 73 // view, which usually is the hosting AppListView. |pagination_model| is |
74 // the paging info shared within the launcher UI. | 74 // the paging info shared within the launcher UI. |
75 AppsGridView(AppsGridViewDelegate* delegate, | 75 AppsGridView(AppsGridViewDelegate* delegate, |
76 PaginationModel* pagination_model); | 76 PaginationModel* pagination_model); |
77 virtual ~AppsGridView(); | 77 virtual ~AppsGridView(); |
78 | 78 |
79 // Sets fixed layout parameters. After setting this, CalculateLayout below | 79 // Sets fixed layout parameters. After setting this, CalculateLayout below |
80 // is no longer called to dynamically choosing those layout params. | 80 // is no longer called to dynamically choosing those layout params. |
81 void SetLayout(int icon_size, int cols, int rows_per_page); | 81 void SetLayout(int icon_size, int cols, int rows_per_page); |
82 | 82 |
83 int cols() { return cols_; } | 83 int cols() const { return cols_; } |
84 int rows_per_page() { return rows_per_page_; } | 84 int rows_per_page() const { return rows_per_page_; } |
85 | 85 |
86 // This resets the grid view to a fresh state for showing the app list. | 86 // This resets the grid view to a fresh state for showing the app list. |
87 void ResetForShowApps(); | 87 void ResetForShowApps(); |
88 | 88 |
89 // Sets |model| to use. Note this does not take ownership of |model|. | 89 // Sets |model| to use. Note this does not take ownership of |model|. |
90 void SetModel(AppListModel* model); | 90 void SetModel(AppListModel* model); |
91 | 91 |
92 // Sets the |item_list| to render. Note this does not take ownership of | 92 // Sets the |item_list| to render. Note this does not take ownership of |
93 // |item_list|. | 93 // |item_list|. |
94 void SetItemList(AppListItemList* item_list); | 94 void SetItemList(AppListItemList* item_list); |
(...skipping 452 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
547 | 547 |
548 // True if the drag_view_ item is a folder item being dragged for reparenting. | 548 // True if the drag_view_ item is a folder item being dragged for reparenting. |
549 bool dragging_for_reparent_item_; | 549 bool dragging_for_reparent_item_; |
550 | 550 |
551 DISALLOW_COPY_AND_ASSIGN(AppsGridView); | 551 DISALLOW_COPY_AND_ASSIGN(AppsGridView); |
552 }; | 552 }; |
553 | 553 |
554 } // namespace app_list | 554 } // namespace app_list |
555 | 555 |
556 #endif // UI_APP_LIST_VIEWS_APPS_GRID_VIEW_H_ | 556 #endif // UI_APP_LIST_VIEWS_APPS_GRID_VIEW_H_ |
OLD | NEW |