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

Side by Side Diff: chrome/browser/web_applications/web_app_mac.h

Issue 14579006: Start app shim when app launched. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address comment Created 7 years, 6 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_WEB_APPLICATIONS_WEB_APP_MAC_H_ 5 #ifndef CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_MAC_H_
6 #define CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_MAC_H_ 6 #define CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_MAC_H_
7 7
8 #include "base/files/file_path.h" 8 #include "base/files/file_path.h"
9 #include "base/gtest_prod_util.h" 9 #include "base/gtest_prod_util.h"
10 #include "base/string16.h" 10 #include "base/string16.h"
11 #include "chrome/browser/shell_integration.h" 11 #include "chrome/browser/shell_integration.h"
12 12
13 #ifdef __OBJC__ 13 #ifdef __OBJC__
14 @class NSDictionary; 14 @class NSDictionary;
15 @class NSString; 15 @class NSString;
16 #else // __OBJC__ 16 #else // __OBJC__
17 class NSDictionary; 17 class NSDictionary;
18 class NSString; 18 class NSString;
19 #endif // __OBJC__ 19 #endif // __OBJC__
20 20
21 namespace web_app { 21 namespace web_app {
22 22
23 // Returns the full path of the .app shim that would be created by 23 // Returns the full path of the .app shim that would be created by
24 // web_app::CreateShortcuts(). 24 // web_app::CreateShortcuts().
25 base::FilePath GetAppInstallPath( 25 base::FilePath GetAppInstallPath(
26 const ShellIntegration::ShortcutInfo& shortcut_info); 26 const ShellIntegration::ShortcutInfo& shortcut_info);
27 27
28 // If necessary, launch the shortcut for an app.
29 void MaybeLaunchShortcut(const ShellIntegration::ShortcutInfo& shortcut_info);
30
28 // Creates a shortcut for a web application. The shortcut is a stub app 31 // Creates a shortcut for a web application. The shortcut is a stub app
29 // that simply loads the browser framework and runs the given app. 32 // that simply loads the browser framework and runs the given app.
30 class WebAppShortcutCreator { 33 class WebAppShortcutCreator {
31 public: 34 public:
32 // Creates a new shortcut based on information in |shortcut_info|. 35 // Creates a new shortcut based on information in |shortcut_info|.
33 // The shortcut stores its user data directory in |user_data_dir|. 36 // The shortcut stores its user data directory in |user_data_dir|.
34 // |chrome_bundle_id| is the CFBundleIdentifier of the Chrome browser bundle. 37 // |chrome_bundle_id| is the CFBundleIdentifier of the Chrome browser bundle.
35 WebAppShortcutCreator( 38 WebAppShortcutCreator(
36 const base::FilePath& user_data_dir, 39 const base::FilePath& user_data_dir,
37 const ShellIntegration::ShortcutInfo& shortcut_info, 40 const ShellIntegration::ShortcutInfo& shortcut_info,
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 // Information about the app. 82 // Information about the app.
80 ShellIntegration::ShortcutInfo info_; 83 ShellIntegration::ShortcutInfo info_;
81 84
82 // The CFBundleIdentifier of the Chrome browser bundle. 85 // The CFBundleIdentifier of the Chrome browser bundle.
83 string16 chrome_bundle_id_; 86 string16 chrome_bundle_id_;
84 }; 87 };
85 88
86 } // namespace web_app 89 } // namespace web_app
87 90
88 #endif // CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_MAC_H_ 91 #endif // CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_MAC_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/app_list/app_list_service_mac_browsertest.mm ('k') | chrome/browser/web_applications/web_app_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698