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

Side by Side Diff: ui/views/view_unittest.cc

Issue 196063002: Move wm/core to wm namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 6 years, 9 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 | « ui/views/touchui/touch_selection_controller_impl.cc ('k') | ui/views/views.gyp » ('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 <map> 5 #include <map>
6 6
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "base/rand_util.h" 8 #include "base/rand_util.h"
9 #include "base/strings/string_util.h" 9 #include "base/strings/string_util.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 3661 matching lines...) Expand 10 before | Expand all | Expand 10 after
3672 ui::Layer* w1_layer = w1->GetNativeView()->layer(); 3672 ui::Layer* w1_layer = w1->GetNativeView()->layer();
3673 ASSERT_EQ("w1", w1_layer->name()); 3673 ASSERT_EQ("w1", w1_layer->name());
3674 ASSERT_EQ("v1 v4 w2 v7", ui::test::ChildLayerNamesAsString(*w1_layer)); 3674 ASSERT_EQ("v1 v4 w2 v7", ui::test::ChildLayerNamesAsString(*w1_layer));
3675 ui::Layer* w2_layer = w1_layer->children()[2]; 3675 ui::Layer* w2_layer = w1_layer->children()[2];
3676 ASSERT_EQ("v5", ui::test::ChildLayerNamesAsString(*w2_layer)); 3676 ASSERT_EQ("v5", ui::test::ChildLayerNamesAsString(*w2_layer));
3677 ui::Layer* v5_layer = w2_layer->children()[0]; 3677 ui::Layer* v5_layer = w2_layer->children()[0];
3678 ASSERT_EQ("v6", ui::test::ChildLayerNamesAsString(*v5_layer)); 3678 ASSERT_EQ("v6", ui::test::ChildLayerNamesAsString(*v5_layer));
3679 3679
3680 { 3680 {
3681 scoped_ptr<ui::LayerTreeOwner> cloned_owner( 3681 scoped_ptr<ui::LayerTreeOwner> cloned_owner(
3682 corewm::RecreateLayers(w1->GetNativeView())); 3682 wm::RecreateLayers(w1->GetNativeView()));
3683 w1_layer = cloned_owner->root(); 3683 w1_layer = cloned_owner->root();
3684 3684
3685 // The order of the layers returned by RecreateWindowLayers() should match 3685 // The order of the layers returned by RecreateWindowLayers() should match
3686 // the order of the layers prior to calling RecreateWindowLayers(). 3686 // the order of the layers prior to calling RecreateWindowLayers().
3687 ASSERT_EQ("w1", w1_layer->name()); 3687 ASSERT_EQ("w1", w1_layer->name());
3688 ASSERT_EQ("v1 v4 w2 v7", ui::test::ChildLayerNamesAsString(*w1_layer)); 3688 ASSERT_EQ("v1 v4 w2 v7", ui::test::ChildLayerNamesAsString(*w1_layer));
3689 w2_layer = w1_layer->children()[2]; 3689 w2_layer = w1_layer->children()[2];
3690 ASSERT_EQ("v5", ui::test::ChildLayerNamesAsString(*w2_layer)); 3690 ASSERT_EQ("v5", ui::test::ChildLayerNamesAsString(*w2_layer));
3691 v5_layer = w2_layer->children()[0]; 3691 v5_layer = w2_layer->children()[0];
3692 ASSERT_EQ("v6", ui::test::ChildLayerNamesAsString(*v5_layer)); 3692 ASSERT_EQ("v6", ui::test::ChildLayerNamesAsString(*v5_layer));
3693 3693
3694 } 3694 }
3695 // The views and the widgets are destroyed when AuraTestHelper::TearDown() 3695 // The views and the widgets are destroyed when AuraTestHelper::TearDown()
3696 // destroys root_window(). 3696 // destroys root_window().
3697 } 3697 }
3698 3698
3699 } // namespace views 3699 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/touchui/touch_selection_controller_impl.cc ('k') | ui/views/views.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698