OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "ui/aura_shell/launcher/launcher_view.h" | 5 #include "ui/aura_shell/launcher/launcher_view.h" |
6 | 6 |
7 #include "base/utf_string_conversions.h" | 7 #include "base/utf_string_conversions.h" |
8 #include "grit/ui_resources.h" | 8 #include "grit/ui_resources.h" |
9 #include "ui/aura/window.h" | 9 #include "ui/aura/window.h" |
10 #include "ui/aura_shell/launcher/app_launcher_button.h" | 10 #include "ui/aura_shell/launcher/app_launcher_button.h" |
11 #include "ui/aura_shell/launcher/launcher_model.h" | 11 #include "ui/aura_shell/launcher/launcher_model.h" |
12 #include "ui/aura_shell/launcher/tabbed_launcher_button.h" | 12 #include "ui/aura_shell/launcher/tabbed_launcher_button.h" |
13 #include "ui/aura_shell/launcher/view_model.h" | 13 #include "ui/aura_shell/launcher/view_model.h" |
14 #include "ui/aura_shell/launcher/view_model_utils.h" | 14 #include "ui/aura_shell/launcher/view_model_utils.h" |
15 #include "ui/aura_shell/shell.h" | 15 #include "ui/aura_shell/shell.h" |
16 #include "ui/aura_shell/shell_delegate.h" | 16 #include "ui/aura_shell/shell_delegate.h" |
17 #include "ui/base/animation/animation.h" | 17 #include "ui/base/animation/animation.h" |
18 #include "ui/base/animation/throb_animation.h" | 18 #include "ui/base/animation/throb_animation.h" |
19 #include "ui/base/models/simple_menu_model.h" | 19 #include "ui/base/models/simple_menu_model.h" |
20 #include "ui/base/resource/resource_bundle.h" | 20 #include "ui/base/resource/resource_bundle.h" |
21 #include "ui/gfx/compositor/layer.h" | 21 #include "ui/gfx/compositor/layer.h" |
22 #include "ui/gfx/image/image.h" | 22 #include "ui/gfx/image/image.h" |
23 #include "ui/views/animation/bounds_animator.h" | 23 #include "ui/views/animation/bounds_animator.h" |
| 24 #include "ui/views/widget/widget.h" |
24 #include "views/controls/button/image_button.h" | 25 #include "views/controls/button/image_button.h" |
25 #include "views/controls/menu/menu_model_adapter.h" | 26 #include "views/controls/menu/menu_model_adapter.h" |
26 #include "views/controls/menu/menu_runner.h" | 27 #include "views/controls/menu/menu_runner.h" |
27 #include "views/widget/widget.h" | |
28 | 28 |
29 using ui::Animation; | 29 using ui::Animation; |
30 using views::View; | 30 using views::View; |
31 | 31 |
32 namespace aura_shell { | 32 namespace aura_shell { |
33 namespace internal { | 33 namespace internal { |
34 | 34 |
35 // Padding between each view. | 35 // Padding between each view. |
36 static const int kHorizontalPadding = 12; | 36 static const int kHorizontalPadding = 12; |
37 | 37 |
(...skipping 566 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
604 } else { | 604 } else { |
605 int view_index = view_model_->GetIndexOfView(sender); | 605 int view_index = view_model_->GetIndexOfView(sender); |
606 // May be -1 while in the process of animating closed. | 606 // May be -1 while in the process of animating closed. |
607 if (view_index != -1) | 607 if (view_index != -1) |
608 delegate->LauncherItemClicked(model_->items()[view_index]); | 608 delegate->LauncherItemClicked(model_->items()[view_index]); |
609 } | 609 } |
610 } | 610 } |
611 | 611 |
612 } // namespace internal | 612 } // namespace internal |
613 } // namespace aura_shell | 613 } // namespace aura_shell |
OLD | NEW |