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

Unified Diff: chrome/browser/ui/views/extensions/extension_install_dialog_view.h

Issue 1534123002: [Extensions] Migrate ExtensionInstallPrompt::Delegate to be a callback (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/extensions/extension_install_dialog_view.h
diff --git a/chrome/browser/ui/views/extensions/extension_install_dialog_view.h b/chrome/browser/ui/views/extensions/extension_install_dialog_view.h
index d0ee5a2edaf4b6318e3d5f4f489d8e97f06c4df3..f9729dd7836f884bc289fcc5e981f9b876feb252 100644
--- a/chrome/browser/ui/views/extensions/extension_install_dialog_view.h
+++ b/chrome/browser/ui/views/extensions/extension_install_dialog_view.h
@@ -39,10 +39,11 @@ class Link;
class ExtensionInstallDialogView : public views::DialogDelegateView,
public views::LinkListener {
public:
- ExtensionInstallDialogView(Profile* profile,
- content::PageNavigator* navigator,
- ExtensionInstallPrompt::Delegate* delegate,
- scoped_ptr<ExtensionInstallPrompt::Prompt> prompt);
+ ExtensionInstallDialogView(
+ Profile* profile,
+ content::PageNavigator* navigator,
+ const ExtensionInstallPrompt::DoneCallback& done_callback,
+ scoped_ptr<ExtensionInstallPrompt::Prompt> prompt);
~ExtensionInstallDialogView() override;
// Returns the interior ScrollView of the dialog. This allows us to inspect
@@ -91,7 +92,7 @@ class ExtensionInstallDialogView : public views::DialogDelegateView,
Profile* profile_;
content::PageNavigator* navigator_;
- ExtensionInstallPrompt::Delegate* delegate_;
+ ExtensionInstallPrompt::DoneCallback done_callback_;
scoped_ptr<ExtensionInstallPrompt::Prompt> prompt_;
// The container view that contains all children (heading, icon, webstore
@@ -109,8 +110,8 @@ class ExtensionInstallDialogView : public views::DialogDelegateView,
// ExperienceSampling: Track this UI event.
scoped_ptr<extensions::ExperienceSamplingEvent> sampling_event_;
- // Set to true once the user's selection has been received and the
- // |delegate_| has been notified.
+ // Set to true once the user's selection has been received and the callback
+ // has been ran.
Avi (use Gerrit) 2015/12/29 03:10:45 "... has been run"?
Devlin 2016/01/04 22:59:23 Dang English. Done.
bool handled_result_;
DISALLOW_COPY_AND_ASSIGN(ExtensionInstallDialogView);

Powered by Google App Engine
This is Rietveld 408576698