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

Unified Diff: ash/shell.cc

Issue 11316245: Move VisibilityController to corewm. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 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 | « ash/shell.h ('k') | ash/wm/visibility_controller.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shell.cc
===================================================================
--- ash/shell.cc (revision 170313)
+++ ash/shell.cc (working copy)
@@ -58,7 +58,7 @@
#include "ash/wm/system_modal_container_layout_manager.h"
#include "ash/wm/user_activity_detector.h"
#include "ash/wm/video_detector.h"
-#include "ash/wm/visibility_controller.h"
+#include "ash/wm/window_animations.h"
#include "ash/wm/window_cycle_controller.h"
#include "ash/wm/window_modality_controller.h"
#include "ash/wm/window_properties.h"
@@ -86,6 +86,7 @@
#include "ui/views/corewm/compound_event_filter.h"
#include "ui/views/corewm/input_method_event_filter.h"
#include "ui/views/corewm/shadow_controller.h"
+#include "ui/views/corewm/visibility_controller.h"
#include "ui/views/focus/focus_manager_factory.h"
#include "ui/views/widget/native_widget_aura.h"
#include "ui/views/widget/widget.h"
@@ -154,6 +155,24 @@
DISALLOW_COPY_AND_ASSIGN(DummyUserWallpaperDelegate);
};
+// A Corewm VisibilityController subclass that calls the Ash animation routine
+// so we can pick up our extended animations. See ash/wm/window_animations.h.
+class AshVisibilityController : public views::corewm::VisibilityController {
+ public:
+ AshVisibilityController() {}
+ virtual ~AshVisibilityController() {}
+
+ private:
+ // Overridden from views::corewm::VisibilityController:
+ virtual bool CallAnimateOnChildWindowVisibilityChanged(
+ aura::Window* window,
+ bool visible) OVERRIDE {
+ return AnimateOnChildWindowVisibilityChanged(window, visible);
+ }
+
+ DISALLOW_COPY_AND_ASSIGN(AshVisibilityController);
+};
+
} // namespace
// static
@@ -486,7 +505,7 @@
stacking_client_.reset(delegate_->CreateStackingClient());
if (stacking_client_.get())
aura::client::SetStackingClient(stacking_client_.get());
- visibility_controller_.reset(new internal::VisibilityController);
+ visibility_controller_.reset(new AshVisibilityController);
drag_drop_controller_.reset(new internal::DragDropController);
user_action_client_.reset(delegate_->CreateUserActionClient());
window_modality_controller_.reset(new internal::WindowModalityController);
« no previous file with comments | « ash/shell.h ('k') | ash/wm/visibility_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698