You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by pu...@apache.org on 2013/09/25 19:51:17 UTC

[1/2] git commit: [CB-4900] Windows 8 Compass plugin have extra define breaks plugin loading

Updated Branches:
  refs/heads/dev d863af777 -> 9d32a1840


[CB-4900] Windows 8 Compass plugin have extra define breaks plugin loading


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/commit/35d45d40
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/tree/35d45d40
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/diff/35d45d40

Branch: refs/heads/dev
Commit: 35d45d40d7c71099990e252271e27205fe5685d4
Parents: b98dd17
Author: Carlos Santana <cs...@gmail.com>
Authored: Tue Sep 24 15:19:29 2013 -0400
Committer: Carlos Santana <cs...@gmail.com>
Committed: Tue Sep 24 15:19:29 2013 -0400

----------------------------------------------------------------------
 src/windows8/CompassProxy.js | 45 +++++++++++++++++++--------------------
 1 file changed, 22 insertions(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/blob/35d45d40/src/windows8/CompassProxy.js
----------------------------------------------------------------------
diff --git a/src/windows8/CompassProxy.js b/src/windows8/CompassProxy.js
index 65ba649..f93fa2b 100644
--- a/src/windows8/CompassProxy.js
+++ b/src/windows8/CompassProxy.js
@@ -1,4 +1,4 @@
-cordova.define("org.apache.cordova.core.device-orientation.CompassProxy", function(require, exports, module) {/*
+/*
  *
  * Licensed to the Apache Software Foundation (ASF) under one
  * or more contributor license agreements.  See the NOTICE file
@@ -19,44 +19,43 @@ cordova.define("org.apache.cordova.core.device-orientation.CompassProxy", functi
  *
 */
 
-/*global Windows:true */
+/*jslint sloppy:true */
+/*global Windows:true, require, module, setTimeout */
 
 var cordova = require('cordova'),
     CompassHeading = require('org.apache.cordova.core.device-orientation.CompassHeading'),
-    CompassError = require('org.apache.cordova.core.device-orientation.CompassError')
+    CompassError = require('org.apache.cordova.core.device-orientation.CompassError');
 
 
 module.exports = {
 
-    onReadingChanged:null,
-    getHeading:function(win,lose) {
+    onReadingChanged: null,
+    getHeading: function (win, lose) {
         var deviceCompass = Windows.Devices.Sensors.Compass.getDefault();
-        if(!deviceCompass) {
-            setTimeout(function(){
+        if (!deviceCompass) {
+            setTimeout(function () {
                 lose(CompassError.COMPASS_NOT_SUPPORTED);
-            },0);
-        }
-        else {
+            }, 0);
+        } else {
 
-            deviceCompass.reportInterval = Math.max(16,deviceCompass.minimumReportInterval);
+            deviceCompass.reportInterval = Math.max(16, deviceCompass.minimumReportInterval);
 
-            this.onReadingChanged = function(e) {
-                var reading = e.reading;
-                var heading = new CompassHeading(reading.headingMagneticNorth, reading.headingTrueNorth,null,reading.timestamp);
+            this.onReadingChanged = function (e) {
+                var reading = e.reading,
+                    heading = new CompassHeading(reading.headingMagneticNorth, reading.headingTrueNorth, null, reading.timestamp);
                 win(heading);
             };
-            deviceCompass.addEventListener("readingchanged",this.onReadingChanged);
+            deviceCompass.addEventListener("readingchanged", this.onReadingChanged);
         }
     },
-    stopHeading:function(win,lose) {
+    stopHeading: function (win, lose) {
         var deviceCompass = Windows.Devices.Sensors.Compass.getDefault();
-        if(!deviceCompass) {
-            setTimeout(function(){
+        if (!deviceCompass) {
+            setTimeout(function () {
                 lose(CompassError.COMPASS_NOT_SUPPORTED);
-            },0);
-        }
-        else {
-            deviceCompass.removeEventListener("readingchanged",this.onReadingChanged);
+            }, 0);
+        } else {
+            deviceCompass.removeEventListener("readingchanged", this.onReadingChanged);
             this.onReadingChanged = null;
             deviceCompass.reportInterval = 0;
             win();
@@ -65,4 +64,4 @@ module.exports = {
     }
 };
 
-require("cordova/windows8/commandProxy").add("Compass",module.exports);});
+require("cordova/windows8/commandProxy").add("Compass", module.exports);


[2/2] git commit: fix merge issue with core removal in namespace

Posted by pu...@apache.org.
fix merge issue with core removal in namespace


Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/commit/9d32a184
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/tree/9d32a184
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/diff/9d32a184

Branch: refs/heads/dev
Commit: 9d32a18404d5fefb609f4e844f955be426b6773d
Parents: 35d45d4 d863af7
Author: purplecabbage <pu...@gmail.com>
Authored: Wed Sep 25 10:50:49 2013 -0700
Committer: purplecabbage <pu...@gmail.com>
Committed: Wed Sep 25 10:50:49 2013 -0700

----------------------------------------------------------------------
 plugin.xml                   | 2 +-
 src/windows8/CompassProxy.js | 8 ++++++--
 2 files changed, 7 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-plugin-device-orientation/blob/9d32a184/src/windows8/CompassProxy.js
----------------------------------------------------------------------
diff --cc src/windows8/CompassProxy.js
index f93fa2b,3064453..8190c1e
--- a/src/windows8/CompassProxy.js
+++ b/src/windows8/CompassProxy.js
@@@ -1,4 -1,4 +1,8 @@@
++<<<<<<< HEAD
 +/*
++=======
+ cordova.define("org.apache.cordova.device-orientation.CompassProxy", function(require, exports, module) {/*
++>>>>>>> d863af77758d0d58f4bdb71cc0ba2f30b9d24228
   *
   * Licensed to the Apache Software Foundation (ASF) under one
   * or more contributor license agreements.  See the NOTICE file
@@@ -19,12 -19,11 +23,12 @@@
   *
  */
  
 -/*global Windows:true */
 +/*jslint sloppy:true */
 +/*global Windows:true, require, module, setTimeout */
  
  var cordova = require('cordova'),
-     CompassHeading = require('org.apache.cordova.core.device-orientation.CompassHeading'),
-     CompassError = require('org.apache.cordova.core.device-orientation.CompassError');
+     CompassHeading = require('org.apache.cordova.device-orientation.CompassHeading'),
 -    CompassError = require('org.apache.cordova.device-orientation.CompassError')
++    CompassError = require('org.apache.cordova.device-orientation.CompassError');
  
  
  module.exports = {