| OLD | NEW |
| 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 namespace app.runtime { | 5 namespace app.runtime { |
| 6 | 6 |
| 7 callback NullCallback = void (); | 7 callback NullCallback = void (); |
| 8 | 8 |
| 9 // A WebIntents intent object. | 9 // A WebIntents intent object. |
| 10 [inline_doc] dictionary Intent { | 10 [inline_doc] dictionary Intent { |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 | 26 |
| 27 // Optional data for the launch. | 27 // Optional data for the launch. |
| 28 [inline_doc] dictionary LaunchData { | 28 [inline_doc] dictionary LaunchData { |
| 29 Intent intent; | 29 Intent intent; |
| 30 }; | 30 }; |
| 31 | 31 |
| 32 interface Events { | 32 interface Events { |
| 33 static void onLaunched(optional LaunchData launchData); | 33 static void onLaunched(optional LaunchData launchData); |
| 34 }; | 34 }; |
| 35 | 35 |
| 36 dictionary IntentResponse { |
| 37 // Identifies the intent. |
| 38 long intentId; |
| 39 |
| 40 // Was this intent successful? (i.e., postSuccess vs postFailure). |
| 41 boolean success; |
| 42 |
| 43 // Data associated with the intent response. |
| 44 any data; |
| 45 }; |
| 46 |
| 47 interface Functions { |
| 48 // postIntentResponse is an internal method to responds to an intent |
| 49 // previously sent to a packaged app. This is identified by intentId, and |
| 50 // should only be invoked at most once per intentId. |
| 51 [nodoc] static void postIntentResponse(IntentResponse intentResponse); |
| 52 }; |
| 36 }; | 53 }; |
| OLD | NEW |