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

Side by Side Diff: athena/extensions/chrome/athena_chrome_app_delegate.h

Issue 563083003: V2 app support step3: Athena's NativeAppWindow (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #ifndef ATHENA_EXTENSIONS_CHROME_ATHENA_APP_DELEGATE_H_ 5 #ifndef ATHENA_EXTENSIONS_CHROME_ATHENA_CHROME_APP_DELEGATE_H_
6 #define ATHENA_EXTENSIONS_CHROME_ATHENA_APP_DELEGATE_H_ 6 #define ATHENA_EXTENSIONS_CHROME_ATHENA_CHROME_APP_DELEGATE_H_
7 7
8 #include "base/callback.h" 8 #include "athena/extensions/athena_app_delegate_base.h"
9 #include "base/memory/scoped_ptr.h"
10 #include "extensions/browser/app_window/app_delegate.h"
11 #include "ui/base/window_open_disposition.h"
12 9
13 namespace athena { 10 namespace athena {
14 11
15 class AthenaAppDelegate : public extensions::AppDelegate { 12 class AthenaChromeAppDelegate : public AthenaAppDelegateBase {
16 public: 13 public:
17 AthenaAppDelegate(); 14 AthenaChromeAppDelegate();
18 virtual ~AthenaAppDelegate(); 15 virtual ~AthenaChromeAppDelegate();
19 16
20 private: 17 private:
21 class NewWindowContentsDelegate;
22
23 // extensions::AppDelegate: 18 // extensions::AppDelegate:
24 virtual void InitWebContents(content::WebContents* web_contents) OVERRIDE; 19 virtual void InitWebContents(content::WebContents* web_contents) OVERRIDE;
25 virtual void ResizeWebContents(content::WebContents* web_contents,
26 const gfx::Size& size) OVERRIDE;
27 virtual content::WebContents* OpenURLFromTab(
28 content::BrowserContext* context,
29 content::WebContents* source,
30 const content::OpenURLParams& params) OVERRIDE;
31 virtual void AddNewContents(content::BrowserContext* context,
32 content::WebContents* new_contents,
33 WindowOpenDisposition disposition,
34 const gfx::Rect& initial_pos,
35 bool user_gesture,
36 bool* was_blocked) OVERRIDE;
37 virtual content::ColorChooser* ShowColorChooser( 20 virtual content::ColorChooser* ShowColorChooser(
38 content::WebContents* web_contents, 21 content::WebContents* web_contents,
39 SkColor initial_color) OVERRIDE; 22 SkColor initial_color) OVERRIDE;
40 virtual void RunFileChooser( 23 virtual void RunFileChooser(
41 content::WebContents* tab, 24 content::WebContents* tab,
42 const content::FileChooserParams& params) OVERRIDE; 25 const content::FileChooserParams& params) OVERRIDE;
43 virtual void RequestMediaAccessPermission( 26 virtual void RequestMediaAccessPermission(
44 content::WebContents* web_contents, 27 content::WebContents* web_contents,
45 const content::MediaStreamRequest& request, 28 const content::MediaStreamRequest& request,
46 const content::MediaResponseCallback& callback, 29 const content::MediaResponseCallback& callback,
47 const extensions::Extension* extension) OVERRIDE; 30 const extensions::Extension* extension) OVERRIDE;
48 virtual bool CheckMediaAccessPermission( 31 virtual bool CheckMediaAccessPermission(
49 content::WebContents* web_contents, 32 content::WebContents* web_contents,
50 const GURL& security_origin, 33 const GURL& security_origin,
51 content::MediaStreamType type, 34 content::MediaStreamType type,
52 const extensions::Extension* extension) OVERRIDE; 35 const extensions::Extension* extension) OVERRIDE;
53 virtual int PreferredIconSize() OVERRIDE;
54 virtual gfx::ImageSkia GetAppDefaultIcon() OVERRIDE;
55 virtual void SetWebContentsBlocked(content::WebContents* web_contents, 36 virtual void SetWebContentsBlocked(content::WebContents* web_contents,
56 bool blocked) OVERRIDE; 37 bool blocked) OVERRIDE;
57 virtual bool IsWebContentsVisible(
58 content::WebContents* web_contents) OVERRIDE;
59 virtual void SetTerminatingCallback(const base::Closure& callback) OVERRIDE;
60 38
61 scoped_ptr<NewWindowContentsDelegate> new_window_contents_delegate_; 39 DISALLOW_COPY_AND_ASSIGN(AthenaChromeAppDelegate);
62 base::Closure terminating_callback_;
63
64 DISALLOW_COPY_AND_ASSIGN(AthenaAppDelegate);
65 }; 40 };
66 41
67 } // namespace athena 42 } // namespace athena
68 43
69 #endif // ATHENA_EXTENSIONS_CHROME_ATHENA_APP_DELEGATE_H_ 44 #endif // ATHENA_EXTENSIONS_CHROME_ATHENA_CHROME_APP_DELEGATE_H_
OLDNEW
« no previous file with comments | « athena/extensions/chrome/athena_apps_client.cc ('k') | athena/extensions/chrome/athena_chrome_app_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698