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

Side by Side Diff: chrome/browser/extensions/api/developer_private/show_permissions_dialog_helper.h

Issue 1008973002: [Extensions UI] Update extensions page to use api methods for permissions prompt (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_EXTENSIONS_API_DEVELOPER_PRIVATE_SHOW_PERMISSIONS_DIALOG_ HELPER_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_DEVELOPER_PRIVATE_SHOW_PERMISSIONS_DIALOG_ HELPER_H_
7
8 #include "base/bind.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "chrome/browser/extensions/extension_install_prompt.h"
11
12 class Profile;
13
14 namespace content {
15 class BrowserContext;
16 class WebContents;
17 }
18
19 namespace extensions {
20 class Extension;
21
22 class ShowPermissionsDialogHelper : public ExtensionInstallPrompt::Delegate {
23 public:
24 ShowPermissionsDialogHelper();
25 ~ShowPermissionsDialogHelper() override;
26
27 void Show(content::WebContents* web_contents,
28 content::BrowserContext* browser_context,
29 const Extension* extension,
30 bool from_extensions_page,
31 const base::Closure& on_complete);
32
33 private:
34 // ExtensionInstallPrompt::Delegate:
35 void InstallUIProceed() override;
36 void InstallUIAbort(bool user_initiated) override;
37
38 void AppInfoDialogClosed();
39
40 base::Closure on_complete_callback_;
41
42 scoped_ptr<ExtensionInstallPrompt> prompt_;
43
44 Profile* profile_;
45
46 std::string extension_id_;
47
48 DISALLOW_COPY_AND_ASSIGN(ShowPermissionsDialogHelper);
49 };
50
51 } // namespace extensions
52
53 #endif // CHROME_BROWSER_EXTENSIONS_API_DEVELOPER_PRIVATE_SHOW_PERMISSIONS_DIAL OG_HELPER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698