| 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_VIEW_H_ | 5 #ifndef UI_APP_LIST_VIEWS_APP_LIST_VIEW_H_ |
| 6 #define UI_APP_LIST_VIEWS_APP_LIST_VIEW_H_ | 6 #define UI_APP_LIST_VIEWS_APP_LIST_VIEW_H_ |
| 7 | 7 |
| 8 #include "base/callback_forward.h" |
| 8 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 9 #include "ui/app_list/app_list_export.h" | 10 #include "ui/app_list/app_list_export.h" |
| 10 #include "ui/app_list/signin_delegate_observer.h" | 11 #include "ui/app_list/signin_delegate_observer.h" |
| 11 #include "ui/views/bubble/bubble_delegate.h" | 12 #include "ui/views/bubble/bubble_delegate.h" |
| 12 | 13 |
| 13 namespace views { | 14 namespace views { |
| 14 class Widget; | 15 class Widget; |
| 15 } | 16 } |
| 16 | 17 |
| 17 namespace app_list { | 18 namespace app_list { |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 // Shows the UI when there are no pending icon loads. Otherwise, starts a | 55 // Shows the UI when there are no pending icon loads. Otherwise, starts a |
| 55 // timer to show the UI when a maximum allowed wait time has expired. | 56 // timer to show the UI when a maximum allowed wait time has expired. |
| 56 void ShowWhenReady(); | 57 void ShowWhenReady(); |
| 57 | 58 |
| 58 void Close(); | 59 void Close(); |
| 59 | 60 |
| 60 void UpdateBounds(); | 61 void UpdateBounds(); |
| 61 | 62 |
| 62 // Overridden from views::View: | 63 // Overridden from views::View: |
| 63 virtual gfx::Size GetPreferredSize() OVERRIDE; | 64 virtual gfx::Size GetPreferredSize() OVERRIDE; |
| 65 virtual void Paint(gfx::Canvas* canvas) OVERRIDE; |
| 64 | 66 |
| 65 // WidgetDelegate overrides: | 67 // WidgetDelegate overrides: |
| 66 virtual bool ShouldHandleSystemCommands() const OVERRIDE; | 68 virtual bool ShouldHandleSystemCommands() const OVERRIDE; |
| 67 | 69 |
| 68 void Prerender(); | 70 void Prerender(); |
| 69 | 71 |
| 70 // Invoked when the sign-in status is changed to switch on/off sign-in view. | 72 // Invoked when the sign-in status is changed to switch on/off sign-in view. |
| 71 void OnSigninStatusChanged(); | 73 void OnSigninStatusChanged(); |
| 72 | 74 |
| 75 // Set a callback to be called the next time any app list paints. |
| 76 static void SetAppListNextPaintCallback(const base::Closure& callback); |
| 77 |
| 73 #if defined(OS_WIN) | 78 #if defined(OS_WIN) |
| 74 HWND GetHWND() const; | 79 HWND GetHWND() const; |
| 75 #endif | 80 #endif |
| 76 | 81 |
| 77 private: | 82 private: |
| 78 // Overridden from views::WidgetDelegateView: | 83 // Overridden from views::WidgetDelegateView: |
| 79 virtual views::View* GetInitiallyFocusedView() OVERRIDE; | 84 virtual views::View* GetInitiallyFocusedView() OVERRIDE; |
| 80 virtual gfx::ImageSkia GetWindowIcon() OVERRIDE; | 85 virtual gfx::ImageSkia GetWindowIcon() OVERRIDE; |
| 81 virtual bool WidgetHasHitTestMask() const OVERRIDE; | 86 virtual bool WidgetHasHitTestMask() const OVERRIDE; |
| 82 virtual void GetWidgetHitTestMask(gfx::Path* mask) const OVERRIDE; | 87 virtual void GetWidgetHitTestMask(gfx::Path* mask) const OVERRIDE; |
| (...skipping 19 matching lines...) Expand all Loading... |
| 102 | 107 |
| 103 AppListMainView* app_list_main_view_; | 108 AppListMainView* app_list_main_view_; |
| 104 SigninView* signin_view_; | 109 SigninView* signin_view_; |
| 105 | 110 |
| 106 DISALLOW_COPY_AND_ASSIGN(AppListView); | 111 DISALLOW_COPY_AND_ASSIGN(AppListView); |
| 107 }; | 112 }; |
| 108 | 113 |
| 109 } // namespace app_list | 114 } // namespace app_list |
| 110 | 115 |
| 111 #endif // UI_APP_LIST_VIEWS_APP_LIST_VIEW_H_ | 116 #endif // UI_APP_LIST_VIEWS_APP_LIST_VIEW_H_ |
| OLD | NEW |