Repository: cordova-plugin-geolocation Updated Branches: refs/heads/master d2b225d6c -> bf8a37341
CB-4596 Date objects are supposed to be DOMTimeStamp (s) Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/repo Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/commit/cbdcedf0 Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/tree/cbdcedf0 Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/diff/cbdcedf0 Branch: refs/heads/master Commit: cbdcedf056bbe8ee932b8542582520f6a3b4eca5 Parents: d2b225d Author: Jesse MacFadyen <[email protected]> Authored: Tue Oct 27 16:45:07 2015 -0700 Committer: Jesse MacFadyen <[email protected]> Committed: Tue Oct 27 16:45:07 2015 -0700 ---------------------------------------------------------------------- README.md | 2 +- doc/de/README.md | 2 +- doc/de/index.md | 2 +- doc/es/README.md | 2 +- doc/es/index.md | 2 +- doc/fr/README.md | 2 +- doc/fr/index.md | 2 +- doc/it/README.md | 2 +- doc/it/index.md | 2 +- doc/ja/README.md | 2 +- doc/ko/README.md | 2 +- doc/ko/index.md | 2 +- doc/pl/README.md | 2 +- doc/zh/README.md | 2 +- doc/zh/index.md | 2 +- www/Position.js | 2 +- www/geolocation.js | 4 ++-- 17 files changed, 18 insertions(+), 18 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/README.md ---------------------------------------------------------------------- diff --git a/README.md b/README.md index 9568c44..c213a5b 100644 --- a/README.md +++ b/README.md @@ -238,7 +238,7 @@ Contains `Position` coordinates and timestamp, created by the geolocation API. - __coords__: A set of geographic coordinates. _(Coordinates)_ -- __timestamp__: Creation timestamp for `coords`. _(Date)_ +- __timestamp__: Creation timestamp for `coords`. _(DOMTimeStamp)_ ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/de/README.md ---------------------------------------------------------------------- diff --git a/doc/de/README.md b/doc/de/README.md index 9cf693e..17e14a5 100644 --- a/doc/de/README.md +++ b/doc/de/README.md @@ -218,7 +218,7 @@ Enthält `Position` koordinaten und Timestamp, erstellt von der Geolocation API. * **coords**: eine Reihe von geographischen Koordinaten. *(Coordinates)* - * **timestamp**: Zeitstempel der Erstellung für `coords` . *(Date)* + * **timestamp**: Zeitstempel der Erstellung für `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/de/index.md ---------------------------------------------------------------------- diff --git a/doc/de/index.md b/doc/de/index.md index 3fe4e4a..92b2079 100644 --- a/doc/de/index.md +++ b/doc/de/index.md @@ -205,7 +205,7 @@ Enthält `Position` koordinaten und Timestamp, erstellt von der Geolocation API. * **coords**: eine Reihe von geographischen Koordinaten. *(Coordinates)* -* **timestamp**: Zeitstempel der Erstellung für `coords` . *(Date)* +* **timestamp**: Zeitstempel der Erstellung für `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/es/README.md ---------------------------------------------------------------------- diff --git a/doc/es/README.md b/doc/es/README.md index 1a4bf00..7808a0e 100644 --- a/doc/es/README.md +++ b/doc/es/README.md @@ -216,7 +216,7 @@ Contiene `Position` coordenadas y timestamp, creado por la API de geolocalizaci * **coordenadas**: un conjunto de coordenadas geográficas. *(Coordenadas)* - * **timestamp**: fecha y hora de creación `coords` . *(Fecha)* + * **timestamp**: fecha y hora de creación `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/es/index.md ---------------------------------------------------------------------- diff --git a/doc/es/index.md b/doc/es/index.md index 043e929..041f3f8 100644 --- a/doc/es/index.md +++ b/doc/es/index.md @@ -164,7 +164,7 @@ Contiene `Position` coordenadas y timestamp, creado por la API de geolocalizaci * **coordenadas**: un conjunto de coordenadas geográficas. *(Coordenadas)* -* **timestamp**: fecha y hora de creación `coords` . *(Fecha)* +* **timestamp**: fecha y hora de creación `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/fr/README.md ---------------------------------------------------------------------- diff --git a/doc/fr/README.md b/doc/fr/README.md index f9865dc..775a487 100644 --- a/doc/fr/README.md +++ b/doc/fr/README.md @@ -177,7 +177,7 @@ Contient `Position` coordonnées et timestamp, créé par l'API de géolocalisat * **coords** : un ensemble de coordonnées géographiques. *(Coordinates)* - * **timestamp** : horodatage de la création de `coords`. *(Date)* + * **timestamp** : horodatage de la création de `coords`. *(DOMTimeStamp)* ## Coordonnées http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/fr/index.md ---------------------------------------------------------------------- diff --git a/doc/fr/index.md b/doc/fr/index.md index bea18dd..4d48637 100644 --- a/doc/fr/index.md +++ b/doc/fr/index.md @@ -164,7 +164,7 @@ Contient `Position` coordonnées et timestamp, créé par l'API de géolocalisat * **coords** : un ensemble de coordonnées géographiques. *(Coordinates)* -* **timestamp** : horodatage de la création de `coords`. *(Date)* +* **timestamp** : horodatage de la création de `coords`. *(DOMTimeStamp)* ## Coordonnées http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/it/README.md ---------------------------------------------------------------------- diff --git a/doc/it/README.md b/doc/it/README.md index 8eb44be..ffa472b 100644 --- a/doc/it/README.md +++ b/doc/it/README.md @@ -218,7 +218,7 @@ Contiene le coordinate della `Position` e timestamp, creato da geolocation API. * **CoOrds**: un insieme di coordinate geografiche. *(Coordinate)* - * **timestamp**: timestamp di creazione per `coords` . *(Data)* + * **timestamp**: timestamp di creazione per `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/it/index.md ---------------------------------------------------------------------- diff --git a/doc/it/index.md b/doc/it/index.md index 41412a0..7ba7c5c 100644 --- a/doc/it/index.md +++ b/doc/it/index.md @@ -205,7 +205,7 @@ Contiene le coordinate della `Position` e timestamp, creato da geolocation API. * **CoOrds**: un insieme di coordinate geografiche. *(Coordinate)* -* **timestamp**: timestamp di creazione per `coords` . *(Data)* +* **timestamp**: timestamp di creazione per `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/ja/README.md ---------------------------------------------------------------------- diff --git a/doc/ja/README.md b/doc/ja/README.md index a519d2c..59c5ed6 100644 --- a/doc/ja/README.md +++ b/doc/ja/README.md @@ -218,7 +218,7 @@ * **coords**: å°çç座æ¨ã®ã»ããã*ï¼åº§æ¨ï¼* - * **timestamp**: 使ã®ã¿ã¤ã ã¹ã¿ã³ãã `coords` ã*ï¼æ¥ï¼* + * **timestamp**: 使ã®ã¿ã¤ã ã¹ã¿ã³ãã `coords` ã*ï¼DOMTimeStampï¼* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/ko/README.md ---------------------------------------------------------------------- diff --git a/doc/ko/README.md b/doc/ko/README.md index 1c03229..dab5005 100644 --- a/doc/ko/README.md +++ b/doc/ko/README.md @@ -218,7 +218,7 @@ * **coords**: ì§ë¦¬ì ì¢í ì§í©. *(ì¢í)* - * **timestamp**: ìì± íì ì¤í¬íì ë í `coords` . *(ë ì§)* + * **timestamp**: ìì± íì ì¤í¬íì ë í `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/ko/index.md ---------------------------------------------------------------------- diff --git a/doc/ko/index.md b/doc/ko/index.md index 2a3e734..19f47c7 100644 --- a/doc/ko/index.md +++ b/doc/ko/index.md @@ -205,7 +205,7 @@ * **coords**: ì§ë¦¬ì ì¢í ì§í©. *(ì¢í)* -* **timestamp**: ìì± íì ì¤í¬íì ë í `coords` . *(ë ì§)* +* **timestamp**: ìì± íì ì¤í¬íì ë í `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/pl/README.md ---------------------------------------------------------------------- diff --git a/doc/pl/README.md b/doc/pl/README.md index 8d6717f..0ef35c4 100644 --- a/doc/pl/README.md +++ b/doc/pl/README.md @@ -218,7 +218,7 @@ Zawiera wspóÅrzÄdne `Position` i sygnatury czasowej, stworzony przez geolocat * **coords**: zestaw wspóÅrzÄdnych geograficznych. *(WspóÅrzÄdne)* - * **timestamp**: Sygnatura czasowa utworzenia dla `coords` . *(Data)* + * **timestamp**: Sygnatura czasowa utworzenia dla `coords` . *(DOMTimeStamp)* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/zh/README.md ---------------------------------------------------------------------- diff --git a/doc/zh/README.md b/doc/zh/README.md index 1ad9931..b2afea5 100644 --- a/doc/zh/README.md +++ b/doc/zh/README.md @@ -218,7 +218,7 @@ Android 2.x 模æ¬å¨ä¸é¤é `enableHighAccuracy` é¸é è¨ç½®çº `true`ï¼å¦ * **coords**ï¼ ä¸çµçå°ç座æ¨ã*ï¼åº§æ¨ï¼* - * **timestamp**ï¼ åµå»ºæéæ³è¨çº `coords` ã*ï¼æ¥æï¼* + * **timestamp**ï¼ åµå»ºæéæ³è¨çº `coords` ã*ï¼DOMTimeStampï¼* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/doc/zh/index.md ---------------------------------------------------------------------- diff --git a/doc/zh/index.md b/doc/zh/index.md index d6d831e..c78a9f7 100644 --- a/doc/zh/index.md +++ b/doc/zh/index.md @@ -205,7 +205,7 @@ Android 2.x 模æ¬å¨ä¸é¤é `enableHighAccuracy` é¸é è¨ç½®çº `true`ï¼å¦ * **coords**ï¼ ä¸çµçå°ç座æ¨ã*ï¼åº§æ¨ï¼* -* **timestamp**ï¼ åµå»ºæéæ³è¨çº `coords` ã*ï¼æ¥æï¼* +* **timestamp**ï¼ åµå»ºæéæ³è¨çº `coords` ã*ï¼DOMTimeStampï¼* ## Coordinates http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/www/Position.js ---------------------------------------------------------------------- diff --git a/www/Position.js b/www/Position.js index f0470de..d6b2c0c 100644 --- a/www/Position.js +++ b/www/Position.js @@ -27,7 +27,7 @@ var Position = function(coords, timestamp) { } else { this.coords = new Coordinates(); } - this.timestamp = (timestamp !== undefined) ? timestamp : new Date(); + this.timestamp = (timestamp !== undefined) ? timestamp : new Date().getTime(); }; module.exports = Position; http://git-wip-us.apache.org/repos/asf/cordova-plugin-geolocation/blob/cbdcedf0/www/geolocation.js ---------------------------------------------------------------------- diff --git a/www/geolocation.js b/www/geolocation.js index 3814919..568c394 100644 --- a/www/geolocation.js +++ b/www/geolocation.js @@ -102,7 +102,7 @@ var geolocation = { velocity:p.velocity, altitudeAccuracy:p.altitudeAccuracy }, - (p.timestamp === undefined ? new Date() : ((p.timestamp instanceof Date) ? p.timestamp : new Date(p.timestamp))) + p.timestamp) ); geolocation.lastPosition = pos; successCallback(pos); @@ -184,7 +184,7 @@ var geolocation = { velocity:p.velocity, altitudeAccuracy:p.altitudeAccuracy }, - (p.timestamp === undefined ? new Date() : ((p.timestamp instanceof Date) ? p.timestamp : new Date(p.timestamp))) + p.timestamp); ); geolocation.lastPosition = pos; successCallback(pos); --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
