This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var IMEI = function(){}; | |
IMEI.prototype.get = function(onSuccess, onFail){ | |
return PhoneGap.exec(onSuccess, onFail, 'IMEI', 'get', []); | |
}; | |
PhoneGap.addConstructor(function(){ | |
PhoneGap.addPlugin('imei', new IMEI()); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var IMEI = function(){}; | |
IMEI.prototype.get = function(onSuccess, onFail){ | |
return cordova.exec(onSuccess, onFail, 'IMEI', 'get', []); | |
}; | |
cordova.addConstructor(function(){ | |
cordova.addPlugin('imei', new IMEI()); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.simonmacdonald.imei; | |
import org.json.JSONArray; | |
import android.content.Context; | |
import android.telephony.TelephonyManager; | |
import com.phonegap.api.Plugin; | |
import com.phonegap.api.PluginResult; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.simonmacdonald.imei; | |
import org.json.JSONArray; | |
import android.content.Context; | |
import android.telephony.TelephonyManager; | |
import org.apache.cordova.api.Plugin; | |
import org.apache.cordova.api.PluginResult; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cordova.define("cordova/plugin/ipaddress", | |
function(require, exports, module) { | |
var exec = require("cordova/exec"); | |
var IPAddress = function () {}; | |
var IPAddressError = function(code, message) { | |
this.code = code || null; | |
this.message = message || ''; | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package org.apache.cordova.plugins; | |
import java.net.InetAddress; | |
import java.net.NetworkInterface; | |
import java.net.SocketException; | |
import java.util.Enumeration; | |
import org.apache.cordova.api.Plugin; | |
import org.apache.cordova.api.PluginResult; | |
import org.json.JSONArray; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script type="text/javascript" charset="utf-8" src="cordova.android.js"></script> | |
<script type="text/javascript" charset="utf-8" src="ipaddress.js"></script> | |
<script> | |
function init(){ | |
console.log("GOT AN ONLOAD!!!") | |
document.addEventListener("deviceready", deviceReady, true); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var remoteFiles = []; | |
function downloadRemotePDF() { | |
var local2User = JSON.parse( localStorage["locallessons"] ); | |
$.each(local2User, function(key) { | |
remoteFiles.push(optionsJSON + local2User[key].idcountries + '/' + local2User[key].idcurriculum + '/' + local2User[key].idoptions + '/pdf/' + local2User[key].pdfname); | |
} | |
downloadFile(); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Copyright (C) 2011 by Daniel Shookowsky | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is | |
furnished to do so, subject to the following conditions: |