Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(36)

Side by Side Diff: chrome/browser/extensions/extension_install_dialog.cc

Issue 10699057: Move application creation and extension install prompt showing off Browser and onto ExtensionTabHel… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/extension_install_dialog.h" 5 #include "chrome/browser/extensions/extension_install_dialog.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/file_path.h" 9 #include "base/file_path.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 return PROCEED; 52 return PROCEED;
53 else if (value == "cancel") 53 else if (value == "cancel")
54 return ABORT; 54 return ABORT;
55 else 55 else
56 NOTREACHED(); 56 NOTREACHED();
57 return DO_NOT_SKIP; 57 return DO_NOT_SKIP;
58 } 58 }
59 59
60 } // namespace 60 } // namespace
61 61
62 void ShowExtensionInstallDialog(Browser* browser, 62 void ShowExtensionInstallDialog(gfx::NativeWindow parent,
63 content::PageNavigator* navigator,
63 ExtensionInstallPrompt::Delegate* delegate, 64 ExtensionInstallPrompt::Delegate* delegate,
64 const ExtensionInstallPrompt::Prompt& prompt) { 65 const ExtensionInstallPrompt::Prompt& prompt) {
65 AutoConfirmForTest auto_confirm = CheckAutoConfirmCommandLineSwitch(); 66 AutoConfirmForTest auto_confirm = CheckAutoConfirmCommandLineSwitch();
66 if (auto_confirm != DO_NOT_SKIP) { 67 if (auto_confirm != DO_NOT_SKIP) {
67 DoAutoConfirm(auto_confirm, delegate); 68 DoAutoConfirm(auto_confirm, delegate);
68 return; 69 return;
69 } 70 }
70 ShowExtensionInstallDialogImpl(browser, delegate, prompt); 71 if (!parent) {
72 delegate->InstallUIAbort(false);
73 return;
74 }
75 ShowExtensionInstallDialogImpl(parent, navigator, delegate, prompt);
71 } 76 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_install_dialog.h ('k') | chrome/browser/extensions/extension_install_prompt.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698