Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_COMMON_MAC_APP_MODE_COMMON_H_ | 5 #ifndef CHROME_COMMON_MAC_APP_MODE_COMMON_H_ |
| 6 #define CHROME_COMMON_MAC_APP_MODE_COMMON_H_ | 6 #define CHROME_COMMON_MAC_APP_MODE_COMMON_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <CoreFoundation/CoreFoundation.h> | 9 #include <Cocoa/Cocoa.h> |
| 10 | 10 |
| 11 // This file contains constants, interfaces, etc. which are common to the | 11 // This file contains constants, interfaces, etc. which are common to the |
| 12 // browser application and the app mode loader (a.k.a. shim). | 12 // browser application and the app mode loader (a.k.a. shim). |
| 13 | 13 |
| 14 namespace app_mode { | 14 namespace app_mode { |
| 15 | 15 |
| 16 // The key under which the browser's bundle ID will be stored in the | 16 // The key under which the browser's bundle ID will be stored in the |
| 17 // app mode launcher bundle's Info.plist. | 17 // app mode launcher bundle's Info.plist. |
| 18 extern const CFStringRef kBrowserBundleIDKey; | 18 extern const CFStringRef kBrowserBundleIDKey; |
| 19 | 19 |
| 20 // The key under which to record the path to the (user-visible) application | 20 // The key under which to record the path to the (user-visible) application |
| 21 // bundle; this key is recorded under the ID given by |kAppPrefsID|. | 21 // bundle; this key is recorded under the ID given by |kAppPrefsID|. |
| 22 extern const CFStringRef kLastRunAppBundlePathPrefsKey; | 22 extern const CFStringRef kLastRunAppBundlePathPrefsKey; |
| 23 | 23 |
| 24 // Key for the shortcut ID. | |
| 25 extern NSString * const kCrAppModeShortcutIDKey; | |
|
Robert Sesek
2012/02/08 00:59:38
nit: no space before *
sail
2012/02/08 01:47:20
Done.
| |
| 26 | |
| 27 // Key for the app's shortcut. | |
| 28 extern NSString * const kCrAppModeShortcutShortNameKey; | |
| 29 | |
| 30 // Key for the app's unrestricted name. | |
| 31 extern NSString * const kCrAppModeShortcutNameKey; | |
| 32 | |
| 33 // Key for the app's URL. | |
| 34 extern NSString * const kCrAppModeShortcutURLKey; | |
| 35 | |
| 24 // Current major/minor version numbers of |ChromeAppModeInfo| (defined below). | 36 // Current major/minor version numbers of |ChromeAppModeInfo| (defined below). |
| 25 const unsigned kCurrentChromeAppModeInfoMajorVersion = 1; | 37 const unsigned kCurrentChromeAppModeInfoMajorVersion = 1; |
| 26 const unsigned kCurrentChromeAppModeInfoMinorVersion = 0; | 38 const unsigned kCurrentChromeAppModeInfoMinorVersion = 0; |
| 27 | 39 |
| 28 // The structure used to pass information from the app mode loader to the | 40 // The structure used to pass information from the app mode loader to the |
| 29 // (browser) framework. This is versioned using major and minor version numbers, | 41 // (browser) framework. This is versioned using major and minor version numbers, |
| 30 // written below as v<major>.<minor>. Version-number checking is done by the | 42 // written below as v<major>.<minor>. Version-number checking is done by the |
| 31 // framework, and the framework must accept all structures with the same major | 43 // framework, and the framework must accept all structures with the same major |
| 32 // version number. It may refuse to load if the major version of the structure | 44 // version number. It may refuse to load if the major version of the structure |
| 33 // is different from the one it accepts. | 45 // is different from the one it accepts. |
| (...skipping 24 matching lines...) Expand all Loading... | |
| 58 // Unrestricted (e.g., several-word) UTF8-encoded name for the shortcut. | 70 // Unrestricted (e.g., several-word) UTF8-encoded name for the shortcut. |
| 59 char* app_mode_name; // Optional: v1.0 | 71 char* app_mode_name; // Optional: v1.0 |
| 60 | 72 |
| 61 // URL for the shortcut. Must be a valid URL. | 73 // URL for the shortcut. Must be a valid URL. |
| 62 char* app_mode_url; // Required: v1.0 | 74 char* app_mode_url; // Required: v1.0 |
| 63 }; | 75 }; |
| 64 | 76 |
| 65 } // namespace app_mode | 77 } // namespace app_mode |
| 66 | 78 |
| 67 #endif // CHROME_COMMON_MAC_APP_MODE_COMMON_H_ | 79 #endif // CHROME_COMMON_MAC_APP_MODE_COMMON_H_ |
| OLD | NEW |