| 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 #include "ash/wm/app_list_controller.h" | 5 #include "ash/wm/app_list_controller.h" |
| 6 | 6 |
| 7 #include "ash/launcher/launcher.h" | 7 #include "ash/launcher/launcher.h" |
| 8 #include "ash/root_window_controller.h" | 8 #include "ash/root_window_controller.h" |
| 9 #include "ash/shell.h" | 9 #include "ash/shell.h" |
| 10 #include "ash/shell_delegate.h" | 10 #include "ash/shell_delegate.h" |
| (...skipping 235 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 246 | 246 |
| 247 //////////////////////////////////////////////////////////////////////////////// | 247 //////////////////////////////////////////////////////////////////////////////// |
| 248 // AppListController, aura::EventFilter implementation: | 248 // AppListController, aura::EventFilter implementation: |
| 249 | 249 |
| 250 ui::EventResult AppListController::OnMouseEvent(ui::MouseEvent* event) { | 250 ui::EventResult AppListController::OnMouseEvent(ui::MouseEvent* event) { |
| 251 if (event->type() == ui::ET_MOUSE_PRESSED) | 251 if (event->type() == ui::ET_MOUSE_PRESSED) |
| 252 ProcessLocatedEvent(event); | 252 ProcessLocatedEvent(event); |
| 253 return ui::ER_UNHANDLED; | 253 return ui::ER_UNHANDLED; |
| 254 } | 254 } |
| 255 | 255 |
| 256 ui::EventResult AppListController::OnGestureEvent(ui::GestureEvent* event) { | 256 void AppListController::OnGestureEvent(ui::GestureEvent* event) { |
| 257 if (event->type() == ui::ET_GESTURE_TAP) | 257 if (event->type() == ui::ET_GESTURE_TAP) |
| 258 ProcessLocatedEvent(event); | 258 ProcessLocatedEvent(event); |
| 259 return ui::ER_UNHANDLED; | |
| 260 } | 259 } |
| 261 | 260 |
| 262 //////////////////////////////////////////////////////////////////////////////// | 261 //////////////////////////////////////////////////////////////////////////////// |
| 263 // AppListController, aura::FocusObserver implementation: | 262 // AppListController, aura::FocusObserver implementation: |
| 264 void AppListController::OnWindowFocused(aura::Window* window) { | 263 void AppListController::OnWindowFocused(aura::Window* window) { |
| 265 if (view_ && is_visible_) { | 264 if (view_ && is_visible_) { |
| 266 aura::Window* applist_container = Shell::GetContainer( | 265 aura::Window* applist_container = Shell::GetContainer( |
| 267 Shell::GetPrimaryRootWindow(), | 266 Shell::GetPrimaryRootWindow(), |
| 268 kShellWindowId_AppListContainer); | 267 kShellWindowId_AppListContainer); |
| 269 if (window->parent() != applist_container) | 268 if (window->parent() != applist_container) |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 356 should_snap_back_ = false; | 355 should_snap_back_ = false; |
| 357 ui::ScopedLayerAnimationSettings animation(widget_animator); | 356 ui::ScopedLayerAnimationSettings animation(widget_animator); |
| 358 animation.SetTransitionDuration(base::TimeDelta::FromMilliseconds( | 357 animation.SetTransitionDuration(base::TimeDelta::FromMilliseconds( |
| 359 app_list::kOverscrollPageTransitionDurationMs)); | 358 app_list::kOverscrollPageTransitionDurationMs)); |
| 360 widget->SetBounds(view_bounds_); | 359 widget->SetBounds(view_bounds_); |
| 361 } | 360 } |
| 362 } | 361 } |
| 363 | 362 |
| 364 } // namespace internal | 363 } // namespace internal |
| 365 } // namespace ash | 364 } // namespace ash |
| OLD | NEW |