Chromium Code Reviews| Index: chrome/browser/extensions/api/app/app_api.h |
| diff --git a/chrome/browser/extensions/api/app/app_api.h b/chrome/browser/extensions/api/app/app_api.h |
| index 864deceee2211f4970ea779b98f5844821cb1424..67d0440db7c9d1bf069e80da0eb3a6a06f508c31 100644 |
| --- a/chrome/browser/extensions/api/app/app_api.h |
| +++ b/chrome/browser/extensions/api/app/app_api.h |
| @@ -10,6 +10,7 @@ |
| class Extension; |
| class Profile; |
| +class GURL; |
| namespace extensions { |
| @@ -33,9 +34,32 @@ class AppClearAllNotificationsFunction : public SyncExtensionFunction { |
| class AppEventRouter { |
| public: |
| - // Dispatches the onLaunched event to the given app. |
| + // Dispatches the onLaunched event to the given app, providing no launch |
| + // data. |
| static void DispatchOnLaunchedEvent(Profile* profile, |
| const Extension* extension); |
| + |
| + // Dispatches the onLaunched event to the given app, providing launch data of |
| + // the form: |
| + // { |
| + // "intent" : { |
| + // "action" : |action|, |
| + // "type" : |mime_type|, |
|
Greg Billock
2012/05/18 14:14:39
If the data is always a FileEntry, the type should
benwells
2012/05/22 13:15:03
Done.
|
| + // "data" : a FileEntry, |
| + // "postResults" : a null function |
|
Greg Billock
2012/05/18 14:14:39
The spec uses two return functions: "postResult" a
benwells
2012/05/22 13:15:03
Done.
|
| + // } |
| + // } |
| + |
| + // launchData.intent.data and launchData.intent.postResults are created in a |
| + // custom dispatch event in javascript. The FileEntry is created from |
| + // |file_system_id| and |base_name|. |
| + static void DispatchOnLaunchedEventWithFileEntry( |
| + Profile* profile, |
| + const Extension* extension, |
| + const string16& action, |
| + const std::string& mime_type, |
| + const std::string& file_system_id, |
| + const std::string& base_name); |
| }; |
| } // namespace extensions |