'type': 'none',
'dependencies': [
'cordova/cordova.gyp:*',
- 'device/cordova_device.gyp:*',
'devicemotion/cordova_devicemotion.gyp:*',
'dialog/cordova_dialog.gyp:*',
'events/cordova_events.gyp:*',
+++ /dev/null
-{
- 'includes':[
- '/usr/include/webapi-plugins/src/common/common.gypi',
- ],
- 'targets': [
- {
- 'target_name': 'tizen_cordova_device',
- 'type': 'loadable_module',
- 'sources': [
- 'cordova_device_api.js',
- 'cordova_device_extension.cc',
- 'cordova_device_extension.h',
- ],
- 'include_dirs': [
- '../',
- '<(SHARED_INTERMEDIATE_DIR)',
- ],
- 'variables': {
- 'packages': [
- 'webapi-plugins',
- ],
- },
- },
- ],
-}
+++ /dev/null
-/*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-// TODO: remove when added to public cordova repository -> begin
-var plugin_name = 'cordova-plugin-device.tizen.Device';
-
-cordova.define(plugin_name, function(require, exports, module) {
-// TODO: remove -> end
-
-function DeviceInfo() {
- this.cordovaVersion = require('cordova/platform').cordovaVersion;
- this.model = tizen.systeminfo.getCapability('http://tizen.org/system/model_name');
- this.platform = tizen.systeminfo.getCapability('http://tizen.org/system/platform.name');
- this.uuid = tizen.systeminfo.getCapability('http://tizen.org/system/tizenid');
- this.version = tizen.systeminfo.getCapability('http://tizen.org/feature/platform.version');
- this.manufacturer = tizen.systeminfo.getCapability('http://tizen.org/system/manufacturer');
- this.isVirtual = -1 !== this.model.toLowerCase().indexOf('emulator');
- this.serial = this.uuid;
-}
-
-var di;
-
-exports = {
- getDeviceInfo: function (success, error) {
- if (!di) {
- di = new DeviceInfo();
- }
- success({
- cordova: di.cordovaVersion,
- model: di.model,
- platform: di.platform,
- uuid: di.uuid,
- version: di.version,
- manufacturer: di.manufacturer, // not documented, but required by tests
- isVirtual: di.isVirtual,
- serial: di.serial
- });
- }
-};
-
-require("cordova/exec/proxy").add("Device", exports);
-
-console.log('Loaded cordova.device API');
-
-// TODO: remove when added to public cordova repository -> begin
-});
-
-exports = function(require) {
- require('cordova-tizen').addPlugin('cordova-plugin-device.device', plugin_name, 'runs');
-};
-// TODO: remove -> end
+++ /dev/null
-/*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include "device/cordova_device_extension.h"
-
-// This will be generated from cordova_device_api.js
-extern const char kSource_cordova_device_api[];
-
-common::Extension* CreateExtension() {
- return new extension::cordova::device::CordovaDeviceExtension();
-}
-
-namespace extension {
-namespace cordova {
-namespace device {
-
-CordovaDeviceExtension::CordovaDeviceExtension() {
- SetExtensionName("tizen.cordova.device");
- SetJavaScriptAPI(kSource_cordova_device_api);
-}
-
-CordovaDeviceExtension::~CordovaDeviceExtension() {}
-
-} // device
-} // cordova
-} // extension
+++ /dev/null
-/*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#ifndef DEVICE_CORDOVA_DEVICE_EXTENSION_H_
-#define DEVICE_CORDOVA_DEVICE_EXTENSION_H_
-
-#include <common/extension.h>
-
-namespace extension {
-namespace cordova {
-namespace device {
-
-class CordovaDeviceExtension : public common::Extension {
- public:
- CordovaDeviceExtension();
- virtual ~CordovaDeviceExtension();
-};
-
-} // device
-} // cordova
-} // extension
-
-#endif // DEVICE_CORDOVA_DEVICE_EXTENSION_H_
"device"
]
},
+ {
+ "file": "plugins/cordova-plugin-device/tizen/Device.js",
+ "id": "cordova-plugin-device.tizen.Device",
+ "runs": true
+ },
{
"file": "plugins/cordova-plugin-device-motion/www/accelerometer.js",
"id": "cordova-plugin-device-motion.Accelerometer",
--- /dev/null
+/*
+ * Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+// TODO: remove when added to public cordova repository -> begin
+var plugin_name = 'cordova-plugin-device.tizen.Device';
+
+cordova.define(plugin_name, function(require, exports, module) {
+// TODO: remove -> end
+
+function DeviceInfo() {
+ this.cordovaVersion = require('cordova/platform').cordovaVersion;
+ this.model = tizen.systeminfo.getCapability('http://tizen.org/system/model_name');
+ this.platform = tizen.systeminfo.getCapability('http://tizen.org/system/platform.name');
+ this.uuid = tizen.systeminfo.getCapability('http://tizen.org/system/tizenid');
+ this.version = tizen.systeminfo.getCapability('http://tizen.org/feature/platform.version');
+ this.manufacturer = tizen.systeminfo.getCapability('http://tizen.org/system/manufacturer');
+ this.isVirtual = -1 !== this.model.toLowerCase().indexOf('emulator');
+ this.serial = this.uuid;
+}
+
+var di;
+
+exports = {
+ getDeviceInfo: function (success, error) {
+ if (!di) {
+ di = new DeviceInfo();
+ }
+ success({
+ cordova: di.cordovaVersion,
+ model: di.model,
+ platform: di.platform,
+ uuid: di.uuid,
+ version: di.version,
+ manufacturer: di.manufacturer, // not documented, but required by tests
+ isVirtual: di.isVirtual,
+ serial: di.serial
+ });
+ }
+};
+
+require("cordova/exec/proxy").add("Device", exports);
+
+console.log('Loaded cordova.device API');
+
+// TODO: remove when added to public cordova repository -> begin
+});
+// TODO: remove -> end