| 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 "base/at_exit.h" | 5 #include "base/at_exit.h" |
| 6 #include "base/bind.h" | 6 #include "base/bind.h" |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/i18n/icu_util.h" | 8 #include "base/i18n/icu_util.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 #include "ui/aura/window.h" | 22 #include "ui/aura/window.h" |
| 23 #include "ui/base/hit_test.h" | 23 #include "ui/base/hit_test.h" |
| 24 #include "ui/compositor/compositor.h" | 24 #include "ui/compositor/compositor.h" |
| 25 #include "ui/compositor/compositor_observer.h" | 25 #include "ui/compositor/compositor_observer.h" |
| 26 #include "ui/compositor/debug_utils.h" | 26 #include "ui/compositor/debug_utils.h" |
| 27 #include "ui/compositor/layer.h" | 27 #include "ui/compositor/layer.h" |
| 28 #include "ui/compositor/test/context_factories_for_test.h" | 28 #include "ui/compositor/test/context_factories_for_test.h" |
| 29 #include "ui/gfx/canvas.h" | 29 #include "ui/gfx/canvas.h" |
| 30 #include "ui/gfx/rect.h" | 30 #include "ui/gfx/rect.h" |
| 31 #include "ui/gfx/skia_util.h" | 31 #include "ui/gfx/skia_util.h" |
| 32 #include "ui/gl/gl_surface.h" |
| 33 |
| 32 #ifndef GL_GLEXT_PROTOTYPES | 34 #ifndef GL_GLEXT_PROTOTYPES |
| 33 #define GL_GLEXT_PROTOTYPES 1 | 35 #define GL_GLEXT_PROTOTYPES 1 |
| 34 #endif | 36 #endif |
| 35 #include "third_party/khronos/GLES2/gl2ext.h" | 37 #include "third_party/khronos/GLES2/gl2ext.h" |
| 36 | 38 |
| 37 #if defined(USE_X11) | 39 #if defined(USE_X11) |
| 38 #include "base/message_loop/message_pump_x11.h" | 40 #include "base/message_loop/message_pump_x11.h" |
| 39 #endif | 41 #endif |
| 40 | 42 |
| 41 using base::TimeTicks; | 43 using base::TimeTicks; |
| (...skipping 241 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 283 DISALLOW_COPY_AND_ASSIGN(SoftwareScrollBench); | 285 DISALLOW_COPY_AND_ASSIGN(SoftwareScrollBench); |
| 284 }; | 286 }; |
| 285 | 287 |
| 286 } // namespace | 288 } // namespace |
| 287 | 289 |
| 288 int main(int argc, char** argv) { | 290 int main(int argc, char** argv) { |
| 289 CommandLine::Init(argc, argv); | 291 CommandLine::Init(argc, argv); |
| 290 | 292 |
| 291 base::AtExitManager exit_manager; | 293 base::AtExitManager exit_manager; |
| 292 | 294 |
| 295 gfx::GLSurface::InitializeOneOff(); |
| 296 |
| 293 // The ContextFactory must exist before any Compositors are created. | 297 // The ContextFactory must exist before any Compositors are created. |
| 294 bool allow_test_contexts = false; | 298 bool allow_test_contexts = false; |
| 295 ui::InitializeContextFactoryForTests(allow_test_contexts); | 299 ui::InitializeContextFactoryForTests(allow_test_contexts); |
| 296 | 300 |
| 297 base::i18n::InitializeICU(); | 301 base::i18n::InitializeICU(); |
| 298 | 302 |
| 299 base::MessageLoopForUI message_loop; | 303 base::MessageLoopForUI message_loop; |
| 300 aura::Env::CreateInstance(); | 304 aura::Env::CreateInstance(); |
| 301 scoped_ptr<aura::TestScreen> test_screen( | 305 scoped_ptr<aura::TestScreen> test_screen( |
| 302 aura::TestScreen::CreateFullscreen()); | 306 aura::TestScreen::CreateFullscreen()); |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 351 ui::PrintLayerHierarchy(root_window->window()->layer(), gfx::Point(100, 100)); | 355 ui::PrintLayerHierarchy(root_window->window()->layer(), gfx::Point(100, 100)); |
| 352 #endif | 356 #endif |
| 353 | 357 |
| 354 root_window->host()->Show(); | 358 root_window->host()->Show(); |
| 355 base::MessageLoopForUI::current()->Run(); | 359 base::MessageLoopForUI::current()->Run(); |
| 356 focus_client.reset(); | 360 focus_client.reset(); |
| 357 root_window.reset(); | 361 root_window.reset(); |
| 358 | 362 |
| 359 return 0; | 363 return 0; |
| 360 } | 364 } |
| OLD | NEW |