| 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/shell.h" | 5 #include "ash/shell.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 326 void Shell::DismissAppList() { | 326 void Shell::DismissAppList() { |
| 327 delegate_->GetAppListPresenter()->Dismiss(); | 327 delegate_->GetAppListPresenter()->Dismiss(); |
| 328 } | 328 } |
| 329 | 329 |
| 330 void Shell::ToggleAppList(aura::Window* window) { | 330 void Shell::ToggleAppList(aura::Window* window) { |
| 331 // If the context window is not given, show it on the target root window. | 331 // If the context window is not given, show it on the target root window. |
| 332 delegate_->GetAppListPresenter()->ToggleAppList( | 332 delegate_->GetAppListPresenter()->ToggleAppList( |
| 333 GetDisplayIdForWindow(window)); | 333 GetDisplayIdForWindow(window)); |
| 334 } | 334 } |
| 335 | 335 |
| 336 bool Shell::IsApplistVisible() const { |
| 337 return delegate_->GetAppListPresenter()->IsVisible(); |
| 338 } |
| 339 |
| 336 bool Shell::GetAppListTargetVisibility() const { | 340 bool Shell::GetAppListTargetVisibility() const { |
| 337 return delegate_->GetAppListPresenter()->GetTargetVisibility(); | 341 return delegate_->GetAppListPresenter()->GetTargetVisibility(); |
| 338 } | 342 } |
| 339 | 343 |
| 340 views::NonClientFrameView* Shell::CreateDefaultNonClientFrameView( | 344 views::NonClientFrameView* Shell::CreateDefaultNonClientFrameView( |
| 341 views::Widget* widget) { | 345 views::Widget* widget) { |
| 342 // Use translucent-style window frames for dialogs. | 346 // Use translucent-style window frames for dialogs. |
| 343 return new CustomFrameViewAsh(widget); | 347 return new CustomFrameViewAsh(widget); |
| 344 } | 348 } |
| 345 | 349 |
| (...skipping 829 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1175 | 1179 |
| 1176 void Shell::OnWindowActivated( | 1180 void Shell::OnWindowActivated( |
| 1177 aura::client::ActivationChangeObserver::ActivationReason reason, | 1181 aura::client::ActivationChangeObserver::ActivationReason reason, |
| 1178 aura::Window* gained_active, | 1182 aura::Window* gained_active, |
| 1179 aura::Window* lost_active) { | 1183 aura::Window* lost_active) { |
| 1180 if (gained_active) | 1184 if (gained_active) |
| 1181 target_root_window_ = gained_active->GetRootWindow(); | 1185 target_root_window_ = gained_active->GetRootWindow(); |
| 1182 } | 1186 } |
| 1183 | 1187 |
| 1184 } // namespace ash | 1188 } // namespace ash |
| OLD | NEW |