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

Side by Side Diff: ash/shelf/shelf_layout_manager_unittest.cc

Issue 23531053: ui/base/animation -> ui/gfx/animation (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge 2 trunk Created 7 years, 3 months 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ash/shelf/shelf_layout_manager.cc ('k') | ash/system/chromeos/network/network_icon_animation.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/shelf/shelf_layout_manager.h" 5 #include "ash/shelf/shelf_layout_manager.h"
6 6
7 #include "ash/accelerators/accelerator_controller.h" 7 #include "ash/accelerators/accelerator_controller.h"
8 #include "ash/accelerators/accelerator_table.h" 8 #include "ash/accelerators/accelerator_table.h"
9 #include "ash/ash_switches.h" 9 #include "ash/ash_switches.h"
10 #include "ash/display/display_controller.h" 10 #include "ash/display/display_controller.h"
(...skipping 14 matching lines...) Expand all
25 #include "ash/test/ash_test_base.h" 25 #include "ash/test/ash_test_base.h"
26 #include "ash/test/launcher_test_api.h" 26 #include "ash/test/launcher_test_api.h"
27 #include "ash/wm/window_properties.h" 27 #include "ash/wm/window_properties.h"
28 #include "ash/wm/window_util.h" 28 #include "ash/wm/window_util.h"
29 #include "base/command_line.h" 29 #include "base/command_line.h"
30 #include "base/strings/utf_string_conversions.h" 30 #include "base/strings/utf_string_conversions.h"
31 #include "ui/aura/client/aura_constants.h" 31 #include "ui/aura/client/aura_constants.h"
32 #include "ui/aura/root_window.h" 32 #include "ui/aura/root_window.h"
33 #include "ui/aura/test/event_generator.h" 33 #include "ui/aura/test/event_generator.h"
34 #include "ui/aura/window.h" 34 #include "ui/aura/window.h"
35 #include "ui/base/animation/animation_container_element.h"
36 #include "ui/compositor/layer.h" 35 #include "ui/compositor/layer.h"
37 #include "ui/compositor/layer_animator.h" 36 #include "ui/compositor/layer_animator.h"
38 #include "ui/compositor/scoped_animation_duration_scale_mode.h" 37 #include "ui/compositor/scoped_animation_duration_scale_mode.h"
38 #include "ui/gfx/animation/animation_container_element.h"
39 #include "ui/gfx/display.h" 39 #include "ui/gfx/display.h"
40 #include "ui/gfx/screen.h" 40 #include "ui/gfx/screen.h"
41 #include "ui/views/controls/label.h" 41 #include "ui/views/controls/label.h"
42 #include "ui/views/layout/fill_layout.h" 42 #include "ui/views/layout/fill_layout.h"
43 #include "ui/views/view.h" 43 #include "ui/views/view.h"
44 #include "ui/views/widget/widget.h" 44 #include "ui/views/widget/widget.h"
45 45
46 #if defined(OS_WIN) 46 #if defined(OS_WIN)
47 #include "base/win/windows_version.h" 47 #include "base/win/windows_version.h"
48 #endif 48 #endif
49 49
50 namespace ash { 50 namespace ash {
51 namespace internal { 51 namespace internal {
52 52
53 namespace { 53 namespace {
54 54
55 void StepWidgetLayerAnimatorToEnd(views::Widget* widget) { 55 void StepWidgetLayerAnimatorToEnd(views::Widget* widget) {
56 ui::AnimationContainerElement* element = 56 gfx::AnimationContainerElement* element =
57 static_cast<ui::AnimationContainerElement*>( 57 static_cast<gfx::AnimationContainerElement*>(
58 widget->GetNativeView()->layer()->GetAnimator()); 58 widget->GetNativeView()->layer()->GetAnimator());
59 element->Step(base::TimeTicks::Now() + base::TimeDelta::FromSeconds(1)); 59 element->Step(base::TimeTicks::Now() + base::TimeDelta::FromSeconds(1));
60 } 60 }
61 61
62 ShelfWidget* GetShelfWidget() { 62 ShelfWidget* GetShelfWidget() {
63 return Shell::GetPrimaryRootWindowController()->shelf(); 63 return Shell::GetPrimaryRootWindowController()->shelf();
64 } 64 }
65 65
66 ShelfLayoutManager* GetShelfLayoutManager() { 66 ShelfLayoutManager* GetShelfLayoutManager() {
67 return Shell::GetPrimaryRootWindowController()->GetShelfLayoutManager(); 67 return Shell::GetPrimaryRootWindowController()->GetShelfLayoutManager();
(...skipping 1763 matching lines...) Expand 10 before | Expand all | Expand 10 after
1831 scoped_ptr<aura::Window> w1(CreateTestWindow()); 1831 scoped_ptr<aura::Window> w1(CreateTestWindow());
1832 w1->Show(); 1832 w1->Show();
1833 wm::ActivateWindow(w1.get()); 1833 wm::ActivateWindow(w1.get());
1834 EXPECT_EQ(SHELF_BACKGROUND_OVERLAP, GetShelfWidget()->GetBackgroundType()); 1834 EXPECT_EQ(SHELF_BACKGROUND_OVERLAP, GetShelfWidget()->GetBackgroundType());
1835 w1->SetProperty(aura::client::kShowStateKey, ui::SHOW_STATE_MAXIMIZED); 1835 w1->SetProperty(aura::client::kShowStateKey, ui::SHOW_STATE_MAXIMIZED);
1836 EXPECT_EQ(SHELF_BACKGROUND_OVERLAP, GetShelfWidget()->GetBackgroundType()); 1836 EXPECT_EQ(SHELF_BACKGROUND_OVERLAP, GetShelfWidget()->GetBackgroundType());
1837 } 1837 }
1838 1838
1839 } // namespace internal 1839 } // namespace internal
1840 } // namespace ash 1840 } // namespace ash
OLDNEW
« no previous file with comments | « ash/shelf/shelf_layout_manager.cc ('k') | ash/system/chromeos/network/network_icon_animation.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698