nativescript-dna-deviceinfo
Advanced tools
Comparing version 3.0.0 to 3.1.0
@@ -64,5 +64,11 @@ var DeviceInfo_1; | ||
static deviceId() { | ||
let systemInfo = new interop.Reference(); | ||
uname(systemInfo); | ||
return NSString.stringWithUTF8String(systemInfo.value.machine).toString(); | ||
const _SYS_NAMELEN = 256; | ||
const utsnamePtr = interop.alloc(interop.sizeof(utsname)); | ||
uname(utsnamePtr); | ||
const sysName = NSString.stringWithUTF8String(utsnamePtr.add(_SYS_NAMELEN * 0)).toString(); | ||
const nodeName = NSString.stringWithUTF8String(utsnamePtr.add(_SYS_NAMELEN * 1)).toString(); | ||
const release = NSString.stringWithUTF8String(utsnamePtr.add(_SYS_NAMELEN * 2)).toString(); | ||
const version = NSString.stringWithUTF8String(utsnamePtr.add(_SYS_NAMELEN * 3)).toString(); | ||
const machine = NSString.stringWithUTF8String(utsnamePtr.add(_SYS_NAMELEN * 4)).toString(); | ||
return machine; | ||
} | ||
@@ -69,0 +75,0 @@ static deviceName() { |
{ | ||
"name": "nativescript-dna-deviceinfo", | ||
"version": "3.0.0", | ||
"version": "3.1.0", | ||
"description": "NativeScript plugin to acquire device information.", | ||
@@ -5,0 +5,0 @@ "main": "deviceinfo", |
@@ -11,2 +11,27 @@ | ||
## Changelogs: | ||
- 3.1.0: Tested on iOS devices, software version 14.2.1. Fixed issues around the API "deviceId" on iOS. | ||
- 3.0.0: Upgraded to NativeScript 7.0 version. **Note**: The plugin is not tested on iOS and Android devices. | ||
- 2.4.3: For iOS, extended the list of devices with Watch-5, iPhone 11(Pro and Max), iPad mini 5th Gen, and Apple Watch Series 5. For Android, support for AndroidX is added. Bumped up version of various packages. | ||
- 2.4.2: Handled crash in the API *cellularServiceProviders* for the Android platform. | ||
- 2.4.1: Updated documentation. | ||
- 2.4.0: Added an API to get location service state. | ||
- 2.3.1: Updated Mobile Country Code and Mobile Network Code. | ||
- 2.3.0: Added APIs to get device orientation and display metrics. | ||
- 2.2.0: Added an API to get a status of Bluetooth. | ||
- 2.1.3: Adjusted the license from Apache-2.0 to MIT. | ||
- 2.1.2: Added the package nativescript-custom-entitlements to dev dependencies to the demo app. | ||
- 2.1.1: The documentation is updated. | ||
- 2.1.0: Added an API to get service set identifier(SSID) of a wireless local area network (WLAN). | ||
- 2.0.0: Changed APIs name for storageVolumes & cellularServiceProviders. | ||
- 1.4.0: Added storageVolumeInfo API. | ||
- 1.3.0: Added externalStoragePaths API. Fixed crashes and compatibility issues with the Android platform. | ||
- 1.2.1: Removed unwanted dependencies. | ||
- 1.2.0: Added an API to retrieve Network Providers, Carriers, related information. | ||
- 1.1.1: Updated document. | ||
- 1.1.0: New APIs related to battery charging status and its charge level. | ||
- 1.0.1: Minor document correction. | ||
- 1.0.0: First release. | ||
## Installation | ||
@@ -424,29 +449,4 @@ | ||
## Changelogs: | ||
- 1.0.0: First release. | ||
- 1.0.1: Minor document correction. | ||
- 1.1.0: New APIs related to battery charging status and its charge level. | ||
- 1.1.1: Updated document. | ||
- 1.2.0: Added an API to retrieve Network Providers, Carriers, related information. | ||
- 1.2.1: Removed unwanted dependencies. | ||
- 1.3.0: Added externalStoragePaths API. Fixed crashes and compatibility issues with the Android platform. | ||
- 1.4.0: Added storageVolumeInfo API. | ||
- 2.0.0: Changed APIs name for storageVolumes & cellularServiceProviders. | ||
- 2.1.0: Added an API to get service set identifier(SSID) of a wireless local area network (WLAN). | ||
- 2.1.1: The documentation is updated. | ||
- 2.1.2: Added the package nativescript-custom-entitlements to dev dependencies to the demo app. | ||
- 2.1.3: Adjusted the license from Apache-2.0 to MIT. | ||
- 2.2.0: Added an API to get a status of Bluetooth. | ||
- 2.3.0: Added APIs to get device orientation and display metrics. | ||
- 2.3.1: Updated Mobile Country Code and Mobile Network Code. | ||
- 2.4.0: Added an API to get location service state. | ||
- 2.4.1: Updated documentation. | ||
- 2.4.2: Handled crash in the API *cellularServiceProviders* for the Android platform. | ||
- 2.4.3: For iOS, extended the list of devices with Watch-5, iPhone 11(Pro and Max), iPad mini 5th Gen, and Apple Watch Series 5. For Android, support for AndroidX is added. Bumped up version of various packages. | ||
- 3.0.0: Upgraded to NativeScript 7.0 version. **Note**: The plugin is not tested on iOS and Android devices. | ||
## License | ||
MIT license (see LICENSE file) |
387981
15392