| 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 #ifndef UI_APP_LIST_VIEWS_APP_LIST_MAIN_VIEW_H_ | 5 #ifndef UI_APP_LIST_VIEWS_APP_LIST_MAIN_VIEW_H_ |
| 6 #define UI_APP_LIST_VIEWS_APP_LIST_MAIN_VIEW_H_ | 6 #define UI_APP_LIST_VIEWS_APP_LIST_MAIN_VIEW_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/memory/scoped_vector.h" | 10 #include "base/memory/scoped_vector.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 | 55 |
| 56 SearchBoxView* search_box_view() const { return search_box_view_; } | 56 SearchBoxView* search_box_view() const { return search_box_view_; } |
| 57 | 57 |
| 58 // If |drag_and_drop_host| is not NULL it will be called upon drag and drop | 58 // If |drag_and_drop_host| is not NULL it will be called upon drag and drop |
| 59 // operations outside the application list. | 59 // operations outside the application list. |
| 60 void SetDragAndDropHostOfCurrentAppList( | 60 void SetDragAndDropHostOfCurrentAppList( |
| 61 ApplicationDragAndDropHost* drag_and_drop_host); | 61 ApplicationDragAndDropHost* drag_and_drop_host); |
| 62 | 62 |
| 63 ContentsView* contents_view() const { return contents_view_; } | 63 ContentsView* contents_view() const { return contents_view_; } |
| 64 | 64 |
| 65 // Returns true if the app list should be centered and in landscape mode. |
| 66 bool ShouldCenterWindow() const; |
| 67 |
| 65 private: | 68 private: |
| 66 class IconLoader; | 69 class IconLoader; |
| 67 | 70 |
| 68 void AddContentsView(); | 71 void AddContentsView(); |
| 69 | 72 |
| 70 // Loads icon image for the apps in the selected page of |pagination_model_|. | 73 // Loads icon image for the apps in the selected page of |pagination_model_|. |
| 71 // |parent| is used to determine the image scale factor to use. | 74 // |parent| is used to determine the image scale factor to use. |
| 72 void PreloadIcons(gfx::NativeView parent); | 75 void PreloadIcons(gfx::NativeView parent); |
| 73 | 76 |
| 74 // Invoked when |icon_loading_wait_timer_| fires. | 77 // Invoked when |icon_loading_wait_timer_| fires. |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 ScopedVector<IconLoader> pending_icon_loaders_; | 110 ScopedVector<IconLoader> pending_icon_loaders_; |
| 108 | 111 |
| 109 base::WeakPtrFactory<AppListMainView> weak_ptr_factory_; | 112 base::WeakPtrFactory<AppListMainView> weak_ptr_factory_; |
| 110 | 113 |
| 111 DISALLOW_COPY_AND_ASSIGN(AppListMainView); | 114 DISALLOW_COPY_AND_ASSIGN(AppListMainView); |
| 112 }; | 115 }; |
| 113 | 116 |
| 114 } // namespace app_list | 117 } // namespace app_list |
| 115 | 118 |
| 116 #endif // UI_APP_LIST_VIEWS_APP_LIST_MAIN_VIEW_H_ | 119 #endif // UI_APP_LIST_VIEWS_APP_LIST_MAIN_VIEW_H_ |
| OLD | NEW |