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

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

Issue 11087071: Making ShowExtensionInstallDialog a callback (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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(gfx::NativeWindow parent, 62 ExtensionInstallDialog::ExtensionInstallDialog() {
63 content::PageNavigator* navigator, 63 }
64 ExtensionInstallPrompt::Delegate* delegate, 64
65 const ExtensionInstallPrompt::Prompt& prompt) { 65 ExtensionInstallDialog::~ExtensionInstallDialog() {
66 }
67
68 void ExtensionInstallDialog::ShowExtensionInstallDialog(
69 gfx::NativeWindow parent,
70 content::PageNavigator* navigator,
71 ExtensionInstallPrompt::Delegate* delegate,
72 const ExtensionInstallPrompt::Prompt& prompt) {
66 AutoConfirmForTest auto_confirm = CheckAutoConfirmCommandLineSwitch(); 73 AutoConfirmForTest auto_confirm = CheckAutoConfirmCommandLineSwitch();
Aaron Boodman 2012/10/11 01:57:57 Is it possible to move this code into ExtensionIns
sail 2012/10/11 02:32:16 Done.
67 if (auto_confirm != DO_NOT_SKIP) { 74 if (auto_confirm != DO_NOT_SKIP) {
68 DoAutoConfirm(auto_confirm, delegate); 75 DoAutoConfirm(auto_confirm, delegate);
69 return; 76 return;
70 } 77 }
71 ShowExtensionInstallDialogImpl(parent, navigator, delegate, prompt); 78 ShowExtensionInstallDialogImpl(parent, navigator, delegate, prompt);
72 } 79 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698