| 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 <memory> | 5 #include <memory> |
| 6 | 6 |
| 7 #include "base/at_exit.h" | 7 #include "base/at_exit.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/i18n/icu_util.h" | 9 #include "base/i18n/icu_util.h" |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| 11 #include "base/memory/ptr_util.h" | 11 #include "base/memory/ptr_util.h" |
| 12 #include "base/message_loop/message_loop.h" | 12 #include "base/message_loop/message_loop.h" |
| 13 #include "base/power_monitor/power_monitor.h" | 13 #include "base/power_monitor/power_monitor.h" |
| 14 #include "base/power_monitor/power_monitor_device_source.h" | 14 #include "base/power_monitor/power_monitor_device_source.h" |
| 15 #include "base/run_loop.h" |
| 15 #include "build/build_config.h" | 16 #include "build/build_config.h" |
| 16 #include "third_party/skia/include/core/SkXfermode.h" | 17 #include "third_party/skia/include/core/SkXfermode.h" |
| 17 #include "ui/aura/client/default_capture_client.h" | 18 #include "ui/aura/client/default_capture_client.h" |
| 18 #include "ui/aura/client/window_tree_client.h" | 19 #include "ui/aura/client/window_tree_client.h" |
| 19 #include "ui/aura/env.h" | 20 #include "ui/aura/env.h" |
| 20 #include "ui/aura/test/test_focus_client.h" | 21 #include "ui/aura/test/test_focus_client.h" |
| 21 #include "ui/aura/test/test_screen.h" | 22 #include "ui/aura/test/test_screen.h" |
| 22 #include "ui/aura/window.h" | 23 #include "ui/aura/window.h" |
| 23 #include "ui/aura/window_delegate.h" | 24 #include "ui/aura/window_delegate.h" |
| 24 #include "ui/aura/window_tree_host.h" | 25 #include "ui/aura/window_tree_host.h" |
| (...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 182 gfx::Rect window3_bounds(10, 10, 50, 50); | 183 gfx::Rect window3_bounds(10, 10, 50, 50); |
| 183 DemoWindowDelegate window_delegate3(SK_ColorGREEN); | 184 DemoWindowDelegate window_delegate3(SK_ColorGREEN); |
| 184 aura::Window window3(&window_delegate3); | 185 aura::Window window3(&window_delegate3); |
| 185 window3.set_id(3); | 186 window3.set_id(3); |
| 186 window3.Init(ui::LAYER_TEXTURED); | 187 window3.Init(ui::LAYER_TEXTURED); |
| 187 window3.SetBounds(window3_bounds); | 188 window3.SetBounds(window3_bounds); |
| 188 window3.Show(); | 189 window3.Show(); |
| 189 window2.AddChild(&window3); | 190 window2.AddChild(&window3); |
| 190 | 191 |
| 191 host->Show(); | 192 host->Show(); |
| 192 base::MessageLoopForUI::current()->Run(); | 193 base::RunLoop().Run(); |
| 193 | 194 |
| 194 return 0; | 195 return 0; |
| 195 } | 196 } |
| 196 | 197 |
| 197 } // namespace | 198 } // namespace |
| 198 | 199 |
| 199 int main(int argc, char** argv) { | 200 int main(int argc, char** argv) { |
| 200 base::CommandLine::Init(argc, argv); | 201 base::CommandLine::Init(argc, argv); |
| 201 | 202 |
| 202 // The exit manager is in charge of calling the dtors of singleton objects. | 203 // The exit manager is in charge of calling the dtors of singleton objects. |
| 203 base::AtExitManager exit_manager; | 204 base::AtExitManager exit_manager; |
| 204 | 205 |
| 205 base::i18n::InitializeICU(); | 206 base::i18n::InitializeICU(); |
| 206 | 207 |
| 207 return DemoMain(); | 208 return DemoMain(); |
| 208 } | 209 } |
| OLD | NEW |