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

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

Issue 10080017: Switch platform apps from a declarative launch container to handling an onLaunched event. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: remove debug logging code Created 8 years, 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ 5 #ifndef CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_
6 #define CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ 6 #define CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "chrome/browser/sessions/session_id.h" 10 #include "chrome/browser/sessions/session_id.h"
11 #include "chrome/browser/extensions/extension_host.h" 11 #include "chrome/browser/extensions/extension_host.h"
12 #include "chrome/browser/ui/base_window.h" 12 #include "chrome/browser/ui/base_window.h"
13 #include "content/public/browser/notification_observer.h" 13 #include "content/public/browser/notification_observer.h"
14 #include "content/public/browser/notification_registrar.h" 14 #include "content/public/browser/notification_registrar.h"
15 15
16 class Extension; 16 class Extension;
17 class ExtensionHost; 17 class ExtensionHost;
18 class ExtensionWindowController; 18 class ExtensionWindowController;
19 class GURL; 19 class GURL;
20 class Profile; 20 class Profile;
21 21
22 namespace content { 22 namespace content {
23 class WebContents; 23 class WebContents;
24 } 24 }
25 25
26 class ShellWindow : public content::NotificationObserver, 26 class ShellWindow : public content::NotificationObserver,
27 public BaseWindow { 27 public BaseWindow {
28 public: 28 public:
29 // TODO(mihaip): Switch from hardcoded defaults to passing in the window
30 // creation parameters to ShellWindow::Create.
31 static const int kDefaultWidth = 512;
32 static const int kDefaultHeight = 384;
33
29 content::WebContents* web_contents() const { return host_->host_contents(); } 34 content::WebContents* web_contents() const { return host_->host_contents(); }
30 const SessionID& session_id() const { return session_id_; } 35 const SessionID& session_id() const { return session_id_; }
31 const ExtensionWindowController* extension_window_controller() const { 36 const ExtensionWindowController* extension_window_controller() const {
32 return extension_window_controller_.get(); 37 return extension_window_controller_.get();
33 } 38 }
34 39
35 static ShellWindow* Create(Profile* profile, 40 static ShellWindow* Create(Profile* profile,
36 const Extension* extension, 41 const Extension* extension,
37 const GURL& url); 42 const GURL& url);
38 43
(...skipping 13 matching lines...) Expand all
52 const SessionID session_id_; 57 const SessionID session_id_;
53 scoped_ptr<ExtensionHost> host_; 58 scoped_ptr<ExtensionHost> host_;
54 content::NotificationRegistrar registrar_; 59 content::NotificationRegistrar registrar_;
55 scoped_ptr<ExtensionWindowController> extension_window_controller_; 60 scoped_ptr<ExtensionWindowController> extension_window_controller_;
56 61
57 private: 62 private:
58 DISALLOW_COPY_AND_ASSIGN(ShellWindow); 63 DISALLOW_COPY_AND_ASSIGN(ShellWindow);
59 }; 64 };
60 65
61 #endif // CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_ 66 #endif // CHROME_BROWSER_UI_EXTENSIONS_SHELL_WINDOW_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/extensions/shell_window_cocoa.mm ('k') | chrome/browser/ui/gtk/extensions/shell_window_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698