Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(361)

Unified Diff: chrome/browser/ui/views/aura/app_list_window.h

Issue 8558031: [Aura] Refactor and update app list window. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync, change initial size close to final size to avoid CardSlider resize animation Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/browser/ui/views/aura/app_list_window.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/aura/app_list_window.h
diff --git a/chrome/browser/ui/views/aura/app_list_window.h b/chrome/browser/ui/views/aura/app_list_window.h
index 282bf1f85d3fe2a69ee416939880d02b09f25558..347028b3624147765b2fc1133ec8bc248600cb7f 100644
--- a/chrome/browser/ui/views/aura/app_list_window.h
+++ b/chrome/browser/ui/views/aura/app_list_window.h
@@ -8,8 +8,7 @@
#include "base/memory/scoped_ptr.h"
#include "chrome/browser/tab_first_render_watcher.h"
-#include "ui/aura/desktop_observer.h"
-#include "ui/gfx/compositor/layer_animation_observer.h"
+#include "ui/aura_shell/shell_delegate.h"
#include "views/widget/widget_delegate.h"
class DOMView;
@@ -19,38 +18,20 @@ class Widget;
}
class AppListWindow : public views::WidgetDelegate,
- public aura::DesktopObserver,
- public ui::LayerAnimationObserver,
public TabFirstRenderWatcher::Delegate {
public:
- // Show/hide app list window.
- static void SetVisible(bool visible);
-
- // Whether app list window is visible (shown or being shown).
- static bool IsVisible();
+ explicit AppListWindow(
+ const aura_shell::ShellDelegate::SetWidgetCallback& callback);
private:
- AppListWindow();
virtual ~AppListWindow();
// views::WidgetDelegate overrides:
virtual void DeleteDelegate() OVERRIDE;
virtual views::View* GetContentsView() OVERRIDE;
- virtual void WindowClosing() OVERRIDE;
virtual views::Widget* GetWidget() OVERRIDE;
virtual const views::Widget* GetWidget() const OVERRIDE;
- // aura::DesktopObserver overrides:
- virtual void OnActiveWindowChanged(aura::Window* active) OVERRIDE;
-
- // ui::LayerAnimationObserver overrides:
- virtual void OnLayerAnimationEnded(
- const ui::LayerAnimationSequence* sequence) OVERRIDE;
- virtual void OnLayerAnimationAborted(
- const ui::LayerAnimationSequence* sequence) OVERRIDE;
- virtual void OnLayerAnimationScheduled(
- const ui::LayerAnimationSequence* sequence) OVERRIDE;
-
// TabFirstRenderWatcher::Delegate implementation:
virtual void OnRenderHostCreated(RenderViewHost* host) OVERRIDE;
virtual void OnTabMainFrameLoaded() OVERRIDE;
@@ -59,22 +40,14 @@ class AppListWindow : public views::WidgetDelegate,
// Initializes the window.
void Init();
- // Shows/hides the window.
- void DoSetVisible(bool visible);
-
- // Current visible app list window.
- static AppListWindow* instance_;
-
views::Widget* widget_;
DOMView* contents_;
- bool is_visible_;
// Monitors TabContents and set |content_rendered_| flag when it's rendered.
scoped_ptr<TabFirstRenderWatcher> tab_watcher_;
- // Flag of whether the web contents is rendered. Showing animation is
- // deferred until this flag is set to true.
- bool content_rendered_;
+ // Callback to set app list widget when it's ready.
+ aura_shell::ShellDelegate::SetWidgetCallback callback_;
DISALLOW_COPY_AND_ASSIGN(AppListWindow);
};
« no previous file with comments | « no previous file | chrome/browser/ui/views/aura/app_list_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698