| 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/app_list/app_list_presenter_delegate.h" | 5 #include "ash/app_list/app_list_presenter_delegate.h" |
| 6 | 6 |
| 7 #include "ash/aura/wm_window_aura.h" | 7 #include "ash/aura/wm_window_aura.h" |
| 8 #include "ash/common/ash_switches.h" | 8 #include "ash/common/ash_switches.h" |
| 9 #include "ash/common/shelf/app_list_button.h" | 9 #include "ash/common/shelf/app_list_button.h" |
| 10 #include "ash/common/shelf/shelf_layout_manager.h" | 10 #include "ash/common/shelf/shelf_layout_manager.h" |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 54 bounds.Subtract(keyboard_controller->current_keyboard_bounds()); | 54 bounds.Subtract(keyboard_controller->current_keyboard_bounds()); |
| 55 | 55 |
| 56 // Apply the |minimum_height|. | 56 // Apply the |minimum_height|. |
| 57 if (bounds.height() < minimum_height) | 57 if (bounds.height() < minimum_height) |
| 58 bounds.set_height(minimum_height); | 58 bounds.set_height(minimum_height); |
| 59 | 59 |
| 60 return bounds.CenterPoint(); | 60 return bounds.CenterPoint(); |
| 61 } | 61 } |
| 62 | 62 |
| 63 bool IsFullscreenAppListEnabled() { | 63 bool IsFullscreenAppListEnabled() { |
| 64 #if defined(OS_CHROMEOS) | |
| 65 return base::CommandLine::ForCurrentProcess()->HasSwitch( | 64 return base::CommandLine::ForCurrentProcess()->HasSwitch( |
| 66 switches::kAshEnableFullscreenAppList); | 65 switches::kAshEnableFullscreenAppList); |
| 67 #else | |
| 68 return false; | |
| 69 #endif | |
| 70 } | 66 } |
| 71 | 67 |
| 72 } // namespace | 68 } // namespace |
| 73 | 69 |
| 74 //////////////////////////////////////////////////////////////////////////////// | 70 //////////////////////////////////////////////////////////////////////////////// |
| 75 // AppListPresenterDelegate, public: | 71 // AppListPresenterDelegate, public: |
| 76 | 72 |
| 77 AppListPresenterDelegate::AppListPresenterDelegate( | 73 AppListPresenterDelegate::AppListPresenterDelegate( |
| 78 app_list::AppListPresenterImpl* presenter, | 74 app_list::AppListPresenterImpl* presenter, |
| 79 app_list::AppListViewDelegateFactory* view_delegate_factory) | 75 app_list::AppListViewDelegateFactory* view_delegate_factory) |
| (...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 277 } | 273 } |
| 278 | 274 |
| 279 //////////////////////////////////////////////////////////////////////////////// | 275 //////////////////////////////////////////////////////////////////////////////// |
| 280 // AppListPresenterDelegate, WmShelfObserver implementation: | 276 // AppListPresenterDelegate, WmShelfObserver implementation: |
| 281 | 277 |
| 282 void AppListPresenterDelegate::OnShelfIconPositionsChanged() { | 278 void AppListPresenterDelegate::OnShelfIconPositionsChanged() { |
| 283 UpdateBounds(); | 279 UpdateBounds(); |
| 284 } | 280 } |
| 285 | 281 |
| 286 } // namespace ash | 282 } // namespace ash |
| OLD | NEW |