OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "content/shell/browser/shell.h" | 5 #include "content/shell/browser/shell.h" |
6 | 6 |
7 #include "content/public/browser/web_contents.h" | 7 #include "content/public/browser/web_contents.h" |
8 #include "content/shell/browser/shell_platform_data_aura.h" | 8 #include "content/shell/browser/shell_platform_data_aura.h" |
9 #include "ui/aura/env.h" | 9 #include "ui/aura/env.h" |
10 #include "ui/aura/test/test_screen.h" | 10 #include "ui/aura/test/test_screen.h" |
11 #include "ui/aura/window.h" | 11 #include "ui/aura/window.h" |
12 #include "ui/aura/window_event_dispatcher.h" | 12 #include "ui/aura/window_event_dispatcher.h" |
13 | 13 |
14 namespace content { | 14 namespace content { |
15 | 15 |
16 // static | 16 // static |
17 void Shell::PlatformInitialize(const gfx::Size& default_window_size) { | 17 void Shell::PlatformInitialize(const gfx::Size& default_window_size) { |
18 CHECK(!platform_); | 18 CHECK(!platform_); |
19 aura::TestScreen* screen = aura::TestScreen::Create(gfx::Size()); | 19 aura::TestScreen* screen = aura::TestScreen::Create(gfx::Size()); |
20 gfx::Screen::SetScreenInstance(gfx::SCREEN_TYPE_NATIVE, screen); | 20 gfx::Screen::SetScreenInstance(screen); |
21 platform_ = new ShellPlatformDataAura(default_window_size); | 21 platform_ = new ShellPlatformDataAura(default_window_size); |
22 } | 22 } |
23 | 23 |
24 void Shell::PlatformExit() { | 24 void Shell::PlatformExit() { |
25 CHECK(platform_); | 25 CHECK(platform_); |
26 delete platform_; | 26 delete platform_; |
27 platform_ = NULL; | 27 platform_ = NULL; |
28 aura::Env::DeleteInstance(); | 28 aura::Env::DeleteInstance(); |
29 } | 29 } |
30 | 30 |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
66 | 66 |
67 void Shell::PlatformSetTitle(const base::string16& title) { | 67 void Shell::PlatformSetTitle(const base::string16& title) { |
68 } | 68 } |
69 | 69 |
70 bool Shell::PlatformHandleContextMenu( | 70 bool Shell::PlatformHandleContextMenu( |
71 const content::ContextMenuParams& params) { | 71 const content::ContextMenuParams& params) { |
72 return false; | 72 return false; |
73 } | 73 } |
74 | 74 |
75 } // namespace content | 75 } // namespace content |
OLD | NEW |