| 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 #import "chrome/browser/ui/cocoa/extensions/extension_install_dialog_controller.
h" | 5 #import "chrome/browser/ui/cocoa/extensions/extension_install_dialog_controller.
h" |
| 6 | 6 |
| 7 #include "base/i18n/rtl.h" | 7 #include "base/i18n/rtl.h" |
| 8 #include "base/mac/bundle_locations.h" | 8 #include "base/mac/bundle_locations.h" |
| 9 #include "base/mac/mac_util.h" | 9 #include "base/mac/mac_util.h" |
| 10 #include "base/memory/scoped_nsobject.h" | 10 #include "base/memory/scoped_nsobject.h" |
| (...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 326 delegate->InstallUIAbort(false); | 326 delegate->InstallUIAbort(false); |
| 327 return; | 327 return; |
| 328 } | 328 } |
| 329 | 329 |
| 330 BrowserWindow* window = browser->window(); | 330 BrowserWindow* window = browser->window(); |
| 331 if (!window) { | 331 if (!window) { |
| 332 delegate->InstallUIAbort(false); | 332 delegate->InstallUIAbort(false); |
| 333 return; | 333 return; |
| 334 } | 334 } |
| 335 | 335 |
| 336 gfx::NativeWindow native_window = window->GetNativeHandle(); | 336 gfx::NativeWindow native_window = window->GetNativeWindow(); |
| 337 | 337 |
| 338 ExtensionInstallDialogController* controller = | 338 ExtensionInstallDialogController* controller = |
| 339 [[ExtensionInstallDialogController alloc] | 339 [[ExtensionInstallDialogController alloc] |
| 340 initWithParentWindow:native_window | 340 initWithParentWindow:native_window |
| 341 profile:profile | 341 profile:profile |
| 342 delegate:delegate | 342 delegate:delegate |
| 343 prompt:prompt]; | 343 prompt:prompt]; |
| 344 | 344 |
| 345 // TODO(mihaip): Switch this to be tab-modal (http://crbug.com/95455) | 345 // TODO(mihaip): Switch this to be tab-modal (http://crbug.com/95455) |
| 346 [controller runAsModalSheet]; | 346 [controller runAsModalSheet]; |
| 347 } | 347 } |
| OLD | NEW |