You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by ra...@apache.org on 2016/05/03 21:23:14 UTC

cordova-windows git commit: CB-10653 Making the windows activation context complete

Repository: cordova-windows
Updated Branches:
  refs/heads/master bbd8de71d -> 58895ee4c


CB-10653 Making the windows activation context complete

 This closes #173


Project: http://git-wip-us.apache.org/repos/asf/cordova-windows/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-windows/commit/58895ee4
Tree: http://git-wip-us.apache.org/repos/asf/cordova-windows/tree/58895ee4
Diff: http://git-wip-us.apache.org/repos/asf/cordova-windows/diff/58895ee4

Branch: refs/heads/master
Commit: 58895ee4c68e2221146625855b570a0dd0fc8cf7
Parents: bbd8de7
Author: Raghav Katyal <ra...@microsoft.com>
Authored: Fri Apr 29 16:00:25 2016 -0700
Committer: Raghav Katyal <ra...@microsoft.com>
Committed: Tue May 3 12:22:54 2016 -0700

----------------------------------------------------------------------
 cordova-js-src/platform.js | 9 +++++----
 template/www/cordova.js    | 9 +++++----
 2 files changed, 10 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/58895ee4/cordova-js-src/platform.js
----------------------------------------------------------------------
diff --git a/cordova-js-src/platform.js b/cordova-js-src/platform.js
index f8764be..d079f57 100644
--- a/cordova-js-src/platform.js
+++ b/cordova-js-src/platform.js
@@ -27,7 +27,8 @@ module.exports = {
             channel = cordova.require('cordova/channel'),
             platform = require('cordova/platform'),
             modulemapper = require('cordova/modulemapper'),
-            configHelper = require('cordova/confighelper');
+            configHelper = require('cordova/confighelper'),
+            utils = require('cordova/utils');
 
         modulemapper.clobbers('cordova/exec/proxy', 'cordova.commandProxy');
 
@@ -56,9 +57,9 @@ module.exports = {
             // OR cordova.require('cordova/platform').activationContext
             // activationContext:{type: actType, args: args};
             var activationHandler = function (e) {
-                var args = e.detail.arguments;
-                var actType = e.detail.type;
-                platform.activationContext = { type: actType, args: args };
+                // Making all the details available as activationContext
+                platform.activationContext = utils.clone(e.detail); 
+                platform.activationContext.args = e.detail.arguments;       /* for backwards compatibility */
 
                 function makePromise(fn) {
                     return new WinJS.Promise(function init(completeDispatch, errorDispatch) {

http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/58895ee4/template/www/cordova.js
----------------------------------------------------------------------
diff --git a/template/www/cordova.js b/template/www/cordova.js
index 37c72c3..db4a7c4 100644
--- a/template/www/cordova.js
+++ b/template/www/cordova.js
@@ -1479,7 +1479,8 @@ module.exports = {
             channel = cordova.require('cordova/channel'),
             platform = require('cordova/platform'),
             modulemapper = require('cordova/modulemapper'),
-            configHelper = require('cordova/confighelper');
+            configHelper = require('cordova/confighelper'),
+            utils = require('cordova/utils');
 
         modulemapper.clobbers('cordova/exec/proxy', 'cordova.commandProxy');
 
@@ -1508,9 +1509,9 @@ module.exports = {
             // OR cordova.require('cordova/platform').activationContext
             // activationContext:{type: actType, args: args};
             var activationHandler = function (e) {
-                var args = e.detail.arguments;
-                var actType = e.detail.type;
-                platform.activationContext = { type: actType, args: args };
+                // Making all the details available as activationContext
+                platform.activationContext = utils.clone(e.detail); 
+                platform.activationContext.args = e.detail.arguments;       /* for backwards compatibility */
 
                 function makePromise(fn) {
                     return new WinJS.Promise(function init(completeDispatch, errorDispatch) {


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org