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 "ash/shell/content_client/shell_browser_main_parts.h" | 5 #include "ash/shell/content_client/shell_browser_main_parts.h" |
6 | 6 |
7 #include "ash/shell/shell_delegate_impl.h" | 7 #include "ash/shell/shell_delegate_impl.h" |
8 #include "ash/shell/window_watcher.h" | 8 #include "ash/shell/window_watcher.h" |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 // Overridden from views::TestViewsDelegate: | 45 // Overridden from views::TestViewsDelegate: |
46 virtual views::NonClientFrameView* CreateDefaultNonClientFrameView( | 46 virtual views::NonClientFrameView* CreateDefaultNonClientFrameView( |
47 views::Widget* widget) OVERRIDE { | 47 views::Widget* widget) OVERRIDE { |
48 return ash::Shell::GetInstance()->CreateDefaultNonClientFrameView(widget); | 48 return ash::Shell::GetInstance()->CreateDefaultNonClientFrameView(widget); |
49 } | 49 } |
50 bool UseTransparentWindows() const OVERRIDE { | 50 bool UseTransparentWindows() const OVERRIDE { |
51 // Ash uses transparent window frames. | 51 // Ash uses transparent window frames. |
52 return true; | 52 return true; |
53 } | 53 } |
54 | 54 |
| 55 views::NativeWidgetHelperAura* CreateNativeWidgetHelper( |
| 56 views::NativeWidgetAura* native_widget) OVERRIDE { |
| 57 // The default behavior of the test delegate is to work in desktop |
| 58 // mode. Return NULL here so NativeWidgetAura uses our RootWindow instead. |
| 59 return NULL; |
| 60 } |
| 61 |
55 private: | 62 private: |
56 DISALLOW_COPY_AND_ASSIGN(ShellViewsDelegate); | 63 DISALLOW_COPY_AND_ASSIGN(ShellViewsDelegate); |
57 }; | 64 }; |
58 | 65 |
59 } // namespace | 66 } // namespace |
60 | 67 |
61 ShellBrowserMainParts::ShellBrowserMainParts( | 68 ShellBrowserMainParts::ShellBrowserMainParts( |
62 const content::MainFunctionParams& parameters) | 69 const content::MainFunctionParams& parameters) |
63 : BrowserMainParts(), | 70 : BrowserMainParts(), |
64 devtools_delegate_(NULL) { | 71 devtools_delegate_(NULL) { |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 } | 118 } |
112 | 119 |
113 ui::Clipboard* ShellBrowserMainParts::GetClipboard() { | 120 ui::Clipboard* ShellBrowserMainParts::GetClipboard() { |
114 if (!clipboard_.get()) | 121 if (!clipboard_.get()) |
115 clipboard_.reset(new ui::Clipboard()); | 122 clipboard_.reset(new ui::Clipboard()); |
116 return clipboard_.get(); | 123 return clipboard_.get(); |
117 } | 124 } |
118 | 125 |
119 } // namespace shell | 126 } // namespace shell |
120 } // namespace ash | 127 } // namespace ash |
OLD | NEW |