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

Side by Side Diff: chrome/browser/ui/extensions/extension_installed_notification.h

Issue 1993583002: Show notification instead of opening app launcher after extension installation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 2016 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_UI_EXTENSIONS_EXTENSION_INSTALLED_NOTIFICATION_H_
6 #define CHROME_BROWSER_UI_EXTENSIONS_EXTENSION_INSTALLED_NOTIFICATION_H_
7
8 #include <string>
9
10 #include "base/memory/ref_counted.h"
11 #include "chrome/browser/notifications/notification_delegate.h"
12 #include "chrome/browser/profiles/profile.h"
13 #include "extensions/common/extension.h"
14
15 class ExtensionInstalledNotification : public NotificationDelegate {
16 public:
17 static void Show(const extensions::Extension* extension, Profile* profile);
18
19 ExtensionInstalledNotification(const extensions::Extension* extension,
20 Profile* profile);
21
22 // NotificationDelegate override:
23 void Click() override;
24 std::string id() const override;
25
26 protected:
27 // This class is ref-counted.
28 ~ExtensionInstalledNotification() override;
29
30 private:
31 scoped_refptr<const extensions::Extension> extension_;
benwells 2016/05/20 00:17:29 I think holding on to a refptr to extension is a b
yoshiki 2016/05/24 16:25:18 Thank you for guidance. Done.
32 Profile* profile_;
33
34 DISALLOW_COPY_AND_ASSIGN(ExtensionInstalledNotification);
35 };
36
37 #endif // CHROME_BROWSER_UI_EXTENSIONS_EXTENSION_INSTALLED_NOTIFICATION_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698