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 <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/string_util.h" | 9 #include "base/string_util.h" |
10 #include "base/utf_string_conversions.h" | 10 #include "base/utf_string_conversions.h" |
(...skipping 22 matching lines...) Expand all Loading... |
33 #include "ui/views/view.h" | 33 #include "ui/views/view.h" |
34 #include "ui/views/views_delegate.h" | 34 #include "ui/views/views_delegate.h" |
35 #include "ui/views/widget/native_widget.h" | 35 #include "ui/views/widget/native_widget.h" |
36 #include "ui/views/widget/root_view.h" | 36 #include "ui/views/widget/root_view.h" |
37 #include "ui/views/window/dialog_delegate.h" | 37 #include "ui/views/window/dialog_delegate.h" |
38 | 38 |
39 #if defined(OS_WIN) | 39 #if defined(OS_WIN) |
40 #include "ui/views/test/test_views_delegate.h" | 40 #include "ui/views/test/test_views_delegate.h" |
41 #endif | 41 #endif |
42 #if defined(USE_AURA) | 42 #if defined(USE_AURA) |
43 #include "ui/aura/event.h" | |
44 #include "ui/aura/root_window.h" | 43 #include "ui/aura/root_window.h" |
45 #include "ui/base/gestures/gesture_recognizer.h" | 44 #include "ui/base/gestures/gesture_recognizer.h" |
46 #endif | 45 #endif |
47 | 46 |
48 using ::testing::_; | 47 using ::testing::_; |
49 | 48 |
50 namespace { | 49 namespace { |
51 | 50 |
52 // Returns true if |ancestor| is an ancestor of |layer|. | 51 // Returns true if |ancestor| is an ancestor of |layer|. |
53 bool LayerIsAncestor(const ui::Layer* ancestor, const ui::Layer* layer) { | 52 bool LayerIsAncestor(const ui::Layer* ancestor, const ui::Layer* layer) { |
(...skipping 3282 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3336 // Set to non default value. | 3335 // Set to non default value. |
3337 v->layer()->set_scale_content(false); | 3336 v->layer()->set_scale_content(false); |
3338 scoped_ptr<ui::Layer> old_layer(v->RecreateLayer()); | 3337 scoped_ptr<ui::Layer> old_layer(v->RecreateLayer()); |
3339 ui::Layer* new_layer = v->layer(); | 3338 ui::Layer* new_layer = v->layer(); |
3340 EXPECT_FALSE(new_layer->scale_content()); | 3339 EXPECT_FALSE(new_layer->scale_content()); |
3341 } | 3340 } |
3342 | 3341 |
3343 #endif // USE_AURA | 3342 #endif // USE_AURA |
3344 | 3343 |
3345 } // namespace views | 3344 } // namespace views |
OLD | NEW |