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

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

Issue 10409023: Remove extension application launch code from Browser (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Browser stuff removed; compiles Created 8 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 | Annotate | Revision Log
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_UI_EXTENSIONS_APPLICATION_LAUNCH_H_
6 #define CHROME_BROWSER_UI_EXTENSIONS_APPLICATION_LAUNCH_H_
7 #pragma once
8
9 #include "chrome/common/extensions/extension_constants.h"
10 #include "webkit/glue/window_open_disposition.h"
11
12 class Browser;
13 class GURL;
14 class Extension;
15 class Profile;
16
17 namespace content {
18 class WebContents;
19 }
20
21 namespace ApplicationLaunch {
sky 2012/05/18 16:04:02 namespaces are typically lower case, eg applicatio
benwells 2012/05/21 03:25:54 Of course ... I must have looked at too much WebKi
22
23 // Open |extension| in |container|, using |disposition| if container type is
24 // TAB. Returns the WebContents* that was created or NULL. If non-empty,
25 // |override_url| is used in place of the app launch url.
26 content::WebContents* OpenApplication(Profile* profile,
27 const Extension* extension,
28 extension_misc::LaunchContainer container,
29 const GURL& override_url,
30 WindowOpenDisposition disposition);
31
32 #if defined(USE_ASH)
33 // Opens |url| in a new application panel window for the specified url.
34 content::WebContents* OpenApplicationPanel(Profile* profile,
35 const Extension* extension,
36 const GURL& url);
37 #endif
38
39 // Opens a new application window for the specified url. If |as_panel| is true,
40 // the application will be opened as a Browser::Type::APP_PANEL in app panel
41 // window, otherwise it will be opened as as either Browser::Type::APP a.k.a.
42 // "thin frame" (if |extension| is NULL) or Browser::Type::EXTENSION_APP (if
43 // |extension| is non-NULL)./ If |app_browser| is not NULL, it is set to the
44 // browser that hosts the returned tab.
45 content::WebContents* OpenApplicationWindow(
46 Profile* profile,
47 const Extension* extension,
48 extension_misc::LaunchContainer container,
49 const GURL& url,
50 Browser** app_browser);
51
52 // Open |url| in an app shortcut window. If |update_shortcut| is true,
53 // update the name, description, and favicon of the shortcut.
54 // There are two kinds of app shortcuts: Shortcuts to a URL,
55 // and shortcuts that open an installed application. This function
56 // is used to open the former. To open the latter, use
57 // Browser::OpenApplicationWindow().
58 content::WebContents* OpenAppShortcutWindow(Profile* profile,
59 const GURL& url,
60 bool update_shortcut);
61
62 // Open an application for |extension| using |disposition|. Returns NULL if
63 // there are no appropriate existing browser windows for |profile|. If
64 // non-empty, |override_url| is used in place of the app launch url.
65 content::WebContents* OpenApplicationTab(Profile* profile,
66 const Extension* extension,
67 const GURL& override_url,
68 WindowOpenDisposition disposition);
69
70 } // namespace ApplicationLaunch
71
72 #endif // CHROME_BROWSER_UI_EXTENSIONS_APPLICATION_LAUNCH_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698