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 "chrome/browser/extensions/api/app_window/app_window_api.h" | 5 #include "chrome/browser/extensions/api/app_window/app_window_api.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/time.h" | 8 #include "base/time.h" |
9 #include "base/values.h" | 9 #include "base/values.h" |
10 #include "chrome/browser/devtools/devtools_window.h" | 10 #include "chrome/browser/devtools/devtools_window.h" |
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
183 switches::kEnableExperimentalExtensionApis)) { | 183 switches::kEnableExperimentalExtensionApis)) { |
184 create_params.frame = ShellWindow::FRAME_NONE; | 184 create_params.frame = ShellWindow::FRAME_NONE; |
185 inject_html_titlebar = true; | 185 inject_html_titlebar = true; |
186 } else if (*options->frame == kNoneFrameOption) { | 186 } else if (*options->frame == kNoneFrameOption) { |
187 create_params.frame = ShellWindow::FRAME_NONE; | 187 create_params.frame = ShellWindow::FRAME_NONE; |
188 } else { | 188 } else { |
189 create_params.frame = ShellWindow::FRAME_CHROME; | 189 create_params.frame = ShellWindow::FRAME_CHROME; |
190 } | 190 } |
191 } | 191 } |
192 | 192 |
| 193 if (options->transparent_background.get() && |
| 194 CommandLine::ForCurrentProcess()->HasSwitch( |
| 195 switches::kEnableExperimentalExtensionApis)) { |
| 196 create_params.transparent_background = *options->transparent_background; |
| 197 } |
| 198 |
193 gfx::Size& minimum_size = create_params.minimum_size; | 199 gfx::Size& minimum_size = create_params.minimum_size; |
194 if (options->min_width.get()) | 200 if (options->min_width.get()) |
195 minimum_size.set_width(*options->min_width); | 201 minimum_size.set_width(*options->min_width); |
196 if (options->min_height.get()) | 202 if (options->min_height.get()) |
197 minimum_size.set_height(*options->min_height); | 203 minimum_size.set_height(*options->min_height); |
198 gfx::Size& maximum_size = create_params.maximum_size; | 204 gfx::Size& maximum_size = create_params.maximum_size; |
199 if (options->max_width.get()) | 205 if (options->max_width.get()) |
200 maximum_size.set_width(*options->max_width); | 206 maximum_size.set_width(*options->max_width); |
201 if (options->max_height.get()) | 207 if (options->max_height.get()) |
202 maximum_size.set_height(*options->max_height); | 208 maximum_size.set_height(*options->max_height); |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
234 if (ShellWindowRegistry::Get(profile())->HadDevToolsAttached(created_view)) { | 240 if (ShellWindowRegistry::Get(profile())->HadDevToolsAttached(created_view)) { |
235 new DevToolsRestorer(this, created_view); | 241 new DevToolsRestorer(this, created_view); |
236 return true; | 242 return true; |
237 } | 243 } |
238 | 244 |
239 SendResponse(true); | 245 SendResponse(true); |
240 return true; | 246 return true; |
241 } | 247 } |
242 | 248 |
243 } // namespace extensions | 249 } // namespace extensions |
OLD | NEW |