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

Side by Side Diff: chrome/browser/extensions/api/tabs/ash_panel_contents.h

Issue 2890983003: Remove AshPanelContents (Closed)
Patch Set: fix errors Created 3 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 2013 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_TABS_ASH_PANEL_CONTENTS_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_TABS_ASH_PANEL_CONTENTS_H_
7
8 #include <stdint.h>
9
10 #include <memory>
11 #include <vector>
12
13 #include "base/macros.h"
14 #include "chrome/browser/ui/ash/launcher/launcher_favicon_loader.h"
15 #include "extensions/browser/app_window/app_window.h"
16
17 class GURL;
18
19 // extensions::AppWindowContents class specific to panel windows created by v1
20 // extenstions. This class maintains a WebContents instance and observes it for
21 // the purpose of passing messages to the extensions system. It also creates
22 // an extensions::WindowController instance for interfacing with the v1
23 // extensions API.
24 class AshPanelContents
25 : public extensions::AppWindowContents,
26 public LauncherFaviconLoader::Delegate {
27 public:
28 explicit AshPanelContents(extensions::AppWindow* host);
29 ~AshPanelContents() override;
30
31 // extensions::AppWindowContents
32 void Initialize(content::BrowserContext* context,
33 content::RenderFrameHost* creator_frame,
34 const GURL& url) override;
35 void LoadContents(int32_t creator_process_id) override;
36 void NativeWindowChanged(
37 extensions::NativeAppWindow* native_app_window) override;
38 void NativeWindowClosed() override;
39 void OnWindowReady() override;
40 content::WebContents* GetWebContents() const override;
41 extensions::WindowController* GetWindowController() const override;
42
43 // LauncherFaviconLoader::Delegate overrides:
44 void FaviconUpdated() override;
45
46 LauncherFaviconLoader* launcher_favicon_loader_for_test() {
47 return launcher_favicon_loader_.get();
48 }
49
50 private:
51 extensions::AppWindow* host_;
52 GURL url_;
53 std::unique_ptr<content::WebContents> web_contents_;
54 std::unique_ptr<LauncherFaviconLoader> launcher_favicon_loader_;
55
56 DISALLOW_COPY_AND_ASSIGN(AshPanelContents);
57 };
58
59 #endif // CHROME_BROWSER_EXTENSIONS_API_TABS_ASH_PANEL_CONTENTS_H_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/BUILD.gn ('k') | chrome/browser/extensions/api/tabs/ash_panel_contents.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698